PHPDeveloper.orghttp://www.phpdeveloper.org
Up-to-the Minute PHP News, views and communityen-usTue, 31 Mar 2015 15:48:50 -050030http://www.phpdeveloper.org/news/14938http://www.phpdeveloper.org/news/14938
On the These Days blog there's a recent post talking about creating a mobile version of your site and how you can detect if the visitor is using a mobile browser or not using WURFL.

WURFL, The Wireless Universal Resource File (WURFL) is an open source project which collects information about all of the different mobile devices in use. It is constantly being updated, so as long as you keep your WURFL definitions up-to-date you don't have to worry about your detection scripts not recognising new devices. By querying a WURFL database with your visitor's User Agent string, you can not only determine whether the device they are using is a mobile device, but whether it has a touch screen, can make phone calls, is a tablet (iPad) and more.

They include a snippet of code that uses the Tera-WURFL service and a call to getCapabilitiesFromAgent to see what kind of client is making the requests and what it supports.

]]>Wed, 11 Aug 2010 08:24:35 -0500http://www.phpdeveloper.org/news/14630http://www.phpdeveloper.org/news/14630
In a recent post o his blog Simon Harris talks about how you can make phone calls and send SMS messages from your PHP applications (well, sort of). He shows how to trigger phone calls and SMS on certain phones by way of an HTML page.

Okay, so you can't really make phone calls and send SMS messages using only HTML; that would be silly. However, if you are developing web sites and web applications for mobile handsets, you can take advantage of some features in XHTML Mobile Profile which make it easy for a user to call a number without typing that number in. You can also use the same mechanism to trigger - on the user's handset - an SMS or MMS dialog with the intended recipient's number and the message content prepopulated.

He includes three examples if it in action (using PHP to render the page) - creating a link to make a call from the HTML, sending an SMS if the text inside a link and doing the same with a MMS message. He uses the WURFL project to make it all work and code snippets are included.