5. Hybrid Applications, GPS, Acceleration, and Other Native Functions with PhoneGap

The PhoneGap library provides an alternative to using the QuickConnect framework discussed in Chapter 4, “GPS, Acceleration, and Other Native Functions with QuickConnect.” Although it does not have the full range of features found in QuickConnect, it is, along with QuickConnect, a popular choice for accessing device information and behavior. The first section of this chapter explains how to access these native iPhone functionalities using the PhoneGap JavaScript API. The second section shows the JavaScript and Objective-C code that underlies the PhoneGap JavaScript API.

Section 1: JavaScript Device Activation

Because PhoneGap is undergoing development at the ...

Get Developing Hybrid Applications for the iPhone: Using HTML, CSS, and JavaScript to Build Dynamic Apps for the iPhone now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.