Well the PhoneGap presentation that Becky Gibson and I gave at OSCON this year seems to have been well received. Thirteen people have rated us so far giving us an average of 4.15 stars out of 5 which I consider to be pretty good. If you are looking for the slides and example code you can find it here.
Next up for me is an internal presentation at the end of the month and then I will head down to Ottawa chapter of CocoaHeads to talk about developing cross platform mobile apps with PhoneGap.
Update: Now available on SlideShare as well.
Monday, August 8, 2011
Saturday, July 30, 2011
Upgrading your PhoneGap Android Application to 1.0.0
With the release of PhoneGap 1.0.0 some folks may run into some problems upgrading their existing applications to the latest version. If you are not using "droidgap create" to generate a brand new Eclipse project using PhoneGap 1.0.0 here are a few things you should be aware of:
- Obviously you'll need to modify the script tag that references phonegap-{ver}.js to be phonegap-1.0.0.js.
- Secondly you'll need to remove the current phonegap-{ver}.jar from the build path and add phonegap-1.0.0.jar to the build path.
- If you run your app and it gets the Force Close dialog then you probably didn't copy plugins.xml into the res/xml directory in your application. If the xml directory doesn't exist create it!
- If you are unable to open a second html page in your app then you're missing the following tag which should be placed in the application tag of your apps AndroidManifest.xml:
<activity android:name="com.phonegap.DroidGap" android:label="@string/app_name" android:configChanges="orientation|keyboardHidden">
<intent-filter>
</intent-filter>
</activity>
Please note after you add this activity you should have two activities under your applications tag. The above activity should not replace the one currently in your application tag.
- If you see and error about PluginManager.addService() not existing then you are using old style plugins. Go into the Plugins .js file and comment out of straight up delete the PluginManager.addService() line from the PhoneGap.addContructor() method. Then you should add a plugin tag to the plugins tag in your plugins.xml.
For instance if you are using the TTS plugin you'd add:
<plugin name="TTS" value="com.phonegap.plugins.speech.TTS"/>
Tuesday, July 19, 2011
My Upcoming Conferences
Apparently people like this PhoneGap thing. So much so I'll be talking about it at three conferences this year.
- OSCON July 27, 2011 - Building Native Mobile Applications with PhoneGap
- InterLab, US Dept. Of Energy October 2011 - Workshop on Building Cross Platform Mobile Apps with PhoneGap
- AnDevCon II November 2011 - Extending Your PhoneGap Application with Plug-ins
Monday, July 11, 2011
Sandman Commission by Jay Odjick
So this arrived in the mail today:
and you'll have to trust me when I say that it looks even better in person. The sketch was done by local Ottawa artist Jay Odjick. I met Jay at one of the presentations at this years Ottawa Writers Festival when we both showed up to see JM DeMatteis and Mike Carey.
Jay is a talented artist who will be releasing his own original graphic novel in a few weeks called Kagagi: The Raven. You can check out this eight page preview on line. If you decide this is something you'd be interested in take the order code, STK436038, to any comic shop and they will be able to get it for you.
and you'll have to trust me when I say that it looks even better in person. The sketch was done by local Ottawa artist Jay Odjick. I met Jay at one of the presentations at this years Ottawa Writers Festival when we both showed up to see JM DeMatteis and Mike Carey.
Jay is a talented artist who will be releasing his own original graphic novel in a few weeks called Kagagi: The Raven. You can check out this eight page preview on line. If you decide this is something you'd be interested in take the order code, STK436038, to any comic shop and they will be able to get it for you.
Thursday, June 23, 2011
FTP Plugin for PhoneGap Android
I did this FTP plugin awhile back but forgot to push it to the main phonegap-plugin's repository. I've pushed it over now and I'm putting together this quick blog post to explain how to use it.
The ftp client allows you to upload and download files from within your PhoneGap Android application. It provides basic get and put functionality.
1. To install the plugin, move www/ftpclient.js to your project's www folder and include a reference to it in your html file after phonegap.{ver}.js.
<script type="text/javascript" charset="utf-8" src="phonegap.js"></script>
<script type="text/javascript" charset="utf-8" src="ftpclient.js"></script>
2. Create a directory within your project called "src/com/phonegap/plugins/ftpclient" and copy "src/com/phonegap/plugins/ftpclient/FtpClient.java" into it.
3. Add the following activity to your AndroidManifest.xml file. It should be added inside the <application> tag.
<activity android:name="com.phonegap.DroidGap" android:label="@string/app_name">
<intent-filter>
</intent-filter>
</activity>
4. Copy "libs/commons-net-2.2.jar" into the libs directory within your project. You will also need to right click on this file in eclipse and add the jar to the build path.
Once installed properly, you should be able to upload files using the following syntax:
window.plugins.ftpclient.put("test.txt", "ftp://username:password@ftp.server.com/test.txt;type=i", win, fail);
and of course download files using:
window.plugins.ftpclient.get("test.txt", "ftp://username:password@ftp.server.com/test.txt;type=i", win, fail);
I'm not sure how many people really need FTP functionality but it was an interesting exercise none the less.
The ftp client allows you to upload and download files from within your PhoneGap Android application. It provides basic get and put functionality.
1. To install the plugin, move www/ftpclient.js to your project's www folder and include a reference to it in your html file after phonegap.{ver}.js.
<script type="text/javascript" charset="utf-8" src="phonegap.js"></script>
<script type="text/javascript" charset="utf-8" src="ftpclient.js"></script>
2. Create a directory within your project called "src/com/phonegap/plugins/ftpclient" and copy "src/com/phonegap/plugins/ftpclient/FtpClient.java" into it.
3. Add the following activity to your AndroidManifest.xml file. It should be added inside the <application> tag.
<activity android:name="com.phonegap.DroidGap" android:label="@string/app_name">
<intent-filter>
</intent-filter>
</activity>
4. Copy "libs/commons-net-2.2.jar" into the libs directory within your project. You will also need to right click on this file in eclipse and add the jar to the build path.
Once installed properly, you should be able to upload files using the following syntax:
window.plugins.ftpclient.put("test.txt", "ftp://username:password@ftp.server.com/test.txt;type=i", win, fail);
and of course download files using:
window.plugins.ftpclient.get("test.txt", "ftp://username:password@ftp.server.com/test.txt;type=i", win, fail);
I'm not sure how many people really need FTP functionality but it was an interesting exercise none the less.
Tuesday, June 21, 2011
Just put the Yankees and Red Sox in Their Own Division
Look I'm not a real big baseball fan anymore. I confess the strike in 1994 sapped a lot of my enthusiasm for the game. However I do keep my else on things tangentially and I'd like to suggest to MLB that they just put the Yankees and Red Sox into their own 2 team division in the American League. I think the division should be called American League Cash Cow.
Basically, both teams would play each other 162 times over the year. The winner of the series would automatically get a buy into the second round of the MLB playoffs. I mean that's what everyone wants right? People just want to see the Red Sox vs the Yankees so let's give it to them.
Honestly, it makes sense. Since 2003 between two teams have been the American League East champions 6 times and wild card entrants 7 times. So of 16 possible play off spots up for grab they've taken 13 so it's not like this is a stretch anyway. Taking a look at the current standings NY is leading the American League East and Boston is in the wild card spot. Business as usual I guess.
So a little bit of re-org will need to happen but it can easily be done by moving Detroit from the American League Central to American League East. That gives us 3 four team divisions and one 2 team division. Playoff spots would go to the winner of the American League East, Central, West and Cash Cow. Additionally the best two records from the East, Central and West divisions would get the wild card spots. This would allow so new blood into the MLB playoffs.
Hey MLB, I don't need any royalties for this so feel free to implement this idea without attribution.
Basically, both teams would play each other 162 times over the year. The winner of the series would automatically get a buy into the second round of the MLB playoffs. I mean that's what everyone wants right? People just want to see the Red Sox vs the Yankees so let's give it to them.
Honestly, it makes sense. Since 2003 between two teams have been the American League East champions 6 times and wild card entrants 7 times. So of 16 possible play off spots up for grab they've taken 13 so it's not like this is a stretch anyway. Taking a look at the current standings NY is leading the American League East and Boston is in the wild card spot. Business as usual I guess.
So a little bit of re-org will need to happen but it can easily be done by moving Detroit from the American League Central to American League East. That gives us 3 four team divisions and one 2 team division. Playoff spots would go to the winner of the American League East, Central, West and Cash Cow. Additionally the best two records from the East, Central and West divisions would get the wild card spots. This would allow so new blood into the MLB playoffs.
Hey MLB, I don't need any royalties for this so feel free to implement this idea without attribution.
Subscribe to:
Posts (Atom)