Playing with PhoneGap? Make your projects even easier

This post is more than 2 years old.

The documentation for creating PhoneGap projects in Eclipse is pretty simple (link), but at 6 or so steps it isn't terribly difficult to make a mistake. While there doesn't seem to be an "official" plugin yet, you should check out the MDS PhoneGap Eclipse plugin. I installed this just now and it worked great. A few caveats though...

  • The plugin currently ships with PhoneGap 1.0, not 1.1. But if you download PhoneGap and extract it, you can point the plugin to the folder for 1.1 and it will make use of that.
  • The plugin will also automatically add jQuery Mobile or Sencha Touch. But the version of jQuery Mobile is quite old. I'd skip that option for now.

All in all - this took a 10 minute process that I had to pay particular attention to into a 2 minute process that even my kitten can do.

Edit: One thing I forgot to mention. When you create the project there will be an error. Open AndroidManifest.xml and remove this: android:xlargeScreens="true". That should clear up the bug that appears on project creation.

Raymond Camden's Picture

About Raymond Camden

Raymond is a senior developer evangelist for Adobe. He focuses on document services, JavaScript, and enterprise cat demos. If you like this article, please consider visiting my Amazon Wishlist or donating via PayPal to show your support. You can even buy me a coffee!

Lafayette, LA

Archived Comments

Comment 1 by Mike posted on 10/11/2011 at 7:44 PM

Ray, Would you say that using eclips is better then using DW 5.5? I have been using the DW 5.5 for phonegap stuff right now and I'm really liking that. Although I have had to hack around to get the new version of phonegap on it but all and all it works very well.

Comment 2 by Raymond Camden posted on 10/11/2011 at 7:45 PM

DW CS5.5 is still shipping with an older version of PhoneGap. From what I understand this will be updated soon.

Comment 3 by Scott Stroz posted on 10/12/2011 at 8:28 PM

I just created a project using this 'plugin' and was able to point it to a copy of the latest jQuery Mobile code and it pulled in that code without issue.

Comment 4 by Scott Stroz posted on 10/12/2011 at 8:32 PM

I am, however, getting JS errors in the jQuery mobile pages - and those error are stopping me from being able to 'build' that app.

Comment 5 by Scott Stroz posted on 10/12/2011 at 8:37 PM

Weird...the error was in the minified jQuery Mobile file, removing the file made it possible for me to 'build' the app. Very cool...thanx for this info.

Comment 6 by Ryan LeTulle posted on 11/24/2011 at 10:29 PM

Love it!

Comment 7 by Mike posted on 2/9/2012 at 10:55 PM

Can we use CFBuilder? I remember you mentioned something before but for some reason I can't find it.


Comment 8 by Raymond Camden posted on 2/9/2012 at 10:57 PM

Absolutely. That's how I run it normally.

Comment 9 by Mike posted on 2/9/2012 at 11:58 PM

I found it here:

but for some reason (I have CFB 2 with hotfix1) when trying to install the ADT got an error and the the another error trying to install GEF:
An error occurred while installing the items
session context was:(profile=profile, phase=org.eclipse.equinox.internal.p2.engine.phases.Install, operand=null --> [R], action=org.eclipse.equinox.internal.p2.touchpoint.eclipse.actions.InstallBundleAction).
The artifact file for osgi.bundle,, was not found.

Comment 10 by Raymond Camden posted on 2/10/2012 at 12:16 AM

Hmm... I'd Google that. It sounds -very- familiar to me. Sorry to punt you to Google, but that's what I'd do. ;) Like I said, I'm pretty sure other CFB users have had this too.

Worse comes to worse, download a new Eclipse install. ;) Remember Eclipse is cool like that, you can have multiple copies.

Comment 11 by Mike posted on 2/10/2012 at 6:47 AM

Thanks Ray,

Home I was able to install it OK. I think I may found a solution:

Will try tomorrow at work.

Thanks again

Comment 12 by Mike posted on 3/13/2012 at 10:44 PM

well it's me again.
I just got back to install PhoneGap on CFBuilder 2. In the mean time I have update to CF10 and CFBuilder 2.01

Now when trying to install ADT I get this error:
Cannot complete the install because one or more required items could not be found.
Software being installed: Android Development Tools 16.0.1.v201112150204-238534 ( 16.0.1.v201112150204-238534)
Missing requirement: Android Development Tools 16.0.1.v201112150204-238534 ( 16.0.1.v201112150204-238534) requires 'org.eclipse.wst.sse.core 0.0.0' but it could not be found.

Googling the error I found a possible solution:
You probably are using a newer version of Eclipse (3.7 Indigo or higher) Try this:

To get around the org.eclipse.wst.xml.core 0.0.0 issue by taking the following steps:

Go to help
Install New Software: Add Name: Indigo/Eclipse 3.7: ""
Select 'WST Server Adapters' under 'Web, XML, Java,..." (the last name in list)
Accept licensing agreement
Restart Eclipse
Resume procedure as described.

from this site:

Would I kill my CF builder installation if I follow the example above?

How can I find which version of Eclipse CF Builder is using?


Comment 13 by Raymond Camden posted on 3/13/2012 at 11:17 PM

Mike - not sure what to recommend here. I used to have ADT installed via my CFB2 install, and it worked, but last time I installed ADT I did it with a virgin Eclipse install, and using 3.7.

Comment 14 by Mike posted on 3/14/2012 at 8:00 PM

Well I went through with the suggested fix and I was able to install ADT and everything seems to work fine, knock on wood.