Easier Drupal Plugin for PhoneGap iOS Installation

There’s been a lot of buzz about PhoneGap this month - the project just released version 1.1.0, the open source project is moving to Apache, and the parent company, Nitobi, was acquired by Adobe.

PhoneGap provides an easy way to make web pages into native mobile apps by wrapping HTML, CSS, and Javascript with an iPhone, Android, Windows Mobile, or Blackberry application. PhoneGap plugins provide services that web apps can’t get, such as interfacing with the phone’s camera.

For Drupal web sites, this means that if you add a mobile theme to your site, you can wrap your site with PhoneGap and have a mobile app. There’s certainly more you can do with mobile and PhoneGap, but that’s the easiest thing to do.

It gets a little trickier if you want to build an actual mobile application that isn’t just your Drupal site, re-skinned. You can certainly write JavaScript that talks to Drupal Services, but it’s pretty painful to write and debug. I wrote a PhoneGap plugin for Drupal for iOS that makes this much easier.

I just finished testing out the plugin on PhoneGap 1.1.0, the latest release, and it works great. I think the biggest frustration will be PhoneGap’s new whitelist feature for only allowing access to certain domains through your app. You will specifically have to add any domains that you retrieve content, images, JavaScript, or CSS from. For instance, code.jquery.com if you use an externally hosted jQuery.

I cleaned up the installation process for the Drupal Plugin by forking two open source projects that the Drupal Plugin for PhoneGap relies on: the Drupal IOS SDK  and ASI HTTP Request and making all of the changes that you previously needed to make yourself in my forks.