Chapter 4. Device Awareness and Content Adaptation

Your new knowledge of mobile markup syntax and best practices makes you ready to adapt Mobile Web content to increase compatibility and usability across mobile devices and browsers. Adapting a Mobile Web site to target mobile browser and device capabilities is achieved by applying two core principles of Mobile Web development: device recognition and content adaptation.

Device awareness is attained by inspecting the User-Agent and other HTTP request headers to identify Web traffic from mobile devices and provide information about device characteristics. Developers use a device database and accompanying API to identify the device that originates the Web request. Once the device is identified, the ...

Get Beginning Smartphone Web Development: Building JavaScript, CSS, HTML and Ajax-based Applications for iPhone, Android, Palm Pre, BlackBerry, Windows Mobile, and Nokia S60 now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.