<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>iPhone Recipes Book &#187; iPhone</title>
	<atom:link href="http://www.iphonerecipesbook.com/tag/iphone/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.iphonerecipesbook.com</link>
	<description>Written by Mark Bates and Mike Mangino</description>
	<lastBuildDate>Thu, 10 Sep 2009 14:57:05 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Apple Push Notifications on Rails</title>
		<link>http://www.iphonerecipesbook.com/2009/07/26/apple-push-notifications-on-rails/</link>
		<comments>http://www.iphonerecipesbook.com/2009/07/26/apple-push-notifications-on-rails/#comments</comments>
		<pubDate>Sun, 26 Jul 2009 15:21:36 +0000</pubDate>
		<dc:creator>mbates</dc:creator>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[apn]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[gem]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[iphone 3.0]]></category>
		<category><![CDATA[push notification]]></category>
		<category><![CDATA[rails]]></category>

		<guid isPermaLink="false">http://www.iphonerecipesbook.com/?p=38</guid>
		<description><![CDATA[The other night I submitted a new iPhone application to the Apple Store. The app, which I&#8217;ll speak about when, and if it gets approved, uses the new Apple Push Notification service available in iPhone OS 3.0. On the server side I have a Rails application that I am using to send the notifications to [...]]]></description>
			<content:encoded><![CDATA[<p>The other night I submitted a new iPhone application to the Apple Store. The app, which I&#8217;ll speak about when, and if it gets approved, uses the new Apple Push Notification service available in iPhone OS 3.0. On the server side I have a Rails application that I am using to send the notifications to Apple. The problem I ran into was how.</p>
<p>Enter the APN on Rails gem. While searching I found one plugin for Rails that mostly worked for me, Sam Soffes&#8217; apple_push_notification plugin. It was a great place to start, but I found that there were things that didn&#8217;t suite me. For starters, not having any tests is always a big turn off for me when it comes to any code. I also didn&#8217;t like that you didn&#8217;t need to save a notification in order to send it. That means you don&#8217;t have a record of what was sent and when. I also wanted to have devices stored separately from the notification. Finally, I wanted to be able to easily configure the plugin. Sam&#8217;s was using constants that would need to be changed when it hit production.</p>
<p>So, with all that said and done I took Sam&#8217;s great work, ripped it apart, and put it back together again, this time in gem form instead of a plugin, and here it is.</p>
<p>There are a few migrations, a few models, and a few Rake tasks, but here is the basic idea of how it works:</p>
<p><script src="http://gist.github.com/154516.js"></script></p>
<p>To get a better understanding of exactly how it works, and what it does, I highly recommend reading the <a href="http://apnonrails.metabates.com/">RDOC</a>.</p>
<p>There are a few things I still would like to add, for example, a controller to do CRUD for devices so iPhones can register with the Rails app. I&#8217;d also like to add a task that talks to Apple and finds out which devices are no longer accepting messages so they can be removed.</p>
<p>If you&#8217;d like to contribute, please feel free and for the project on GitHub:<br />
<a href="http://github.com/markbates/apn_on_rails/tree">http://github.com/markbates/apn_on_rails/tree</a></p>
<p>Again, a special thanks to Fabien Penso and Sam Soffes for their initial work on this project.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.iphonerecipesbook.com/2009/07/26/apple-push-notifications-on-rails/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>Call For Submissions to the iPhone Recipes Book</title>
		<link>http://www.iphonerecipesbook.com/2009/05/20/call-for-submissions-to-the-iphone-recipes-book/</link>
		<comments>http://www.iphonerecipesbook.com/2009/05/20/call-for-submissions-to-the-iphone-recipes-book/#comments</comments>
		<pubDate>Wed, 20 May 2009 11:00:49 +0000</pubDate>
		<dc:creator>mbates</dc:creator>
				<category><![CDATA[Announcements]]></category>
		<category><![CDATA[Book]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[iPhone API]]></category>
		<category><![CDATA[iPhone Recipes]]></category>
		<category><![CDATA[iPhone SDK]]></category>
		<category><![CDATA[mark bates]]></category>
		<category><![CDATA[mike mangino]]></category>
		<category><![CDATA[Pragmatic Bookshelf]]></category>
		<category><![CDATA[Pragmatic Programmers]]></category>
		<category><![CDATA[recipes]]></category>

		<guid isPermaLink="false">http://www.iphonerecipesbook.com/?p=3</guid>
		<description><![CDATA[In just over a year since the iPhone API was released, we&#8217;ve seen some incredible applications created. It&#8217;s clear that there are some really sharp developers in the iPhone community. 
Do you have a really cool solution to a common problem? We&#8217;d love to hear it. We&#8217;re looking for bite sized recipes for our &#8220;iPhone [...]]]></description>
			<content:encoded><![CDATA[<p>In just over a year since the iPhone API was released, we&#8217;ve seen some incredible applications created. It&#8217;s clear that there are some really sharp developers in the iPhone community. </p>
<p>Do you have a really cool solution to a common problem? We&#8217;d love to hear it. We&#8217;re looking for bite sized recipes for our &#8220;iPhone Recipes&#8221; book to be published by the Pragmatic Bookshelf and edited by Mark Bates and Mike Mangino. This is your opportunity to show your chops to the community as a whole. In particular, we&#8217;re looking for easily understandable, general purpose recipes that aren&#8217;t already well documented. </p>
<p>For example, do you have a great method showing a preferences screen inside your application? Maybe you know a cool trick loading images from the web asynchronously. We&#8217;re looking for tips that save you time that other people could benefit from. We&#8217;re not asking you to share your application&#8217;s secret sauce, just a few of the toppings. </p>
<p>Do you have an idea for a recipe but don&#8217;t want to write it yourself? We&#8217;re collecting a list of recipe ideas at <a href="http://www.iphonerecipesbook.com/2009/07/07/our-recipe-ideas/">http://www.iphonerecipesbook.com/2009/07/07/our-recipe-ideas/</a>. You can add your ideas in a comment there.</p>
<p>To propose a recipe idea, here&#8217;s what we need from you:</p>
<p>A paragraph or two describing the problem that the recipe solves.<br />
A sentence or two indicating what the solution will be.<br />
The OS version(s) to which the recipe applies.</p>
<p>You should already have working code. You can send some along if it helps convey your idea.</p>
<p>Email your idea to us at submissions@iphonerecipesbook.com by August 1st (or sooner!)  We&#8217;ll let you know if we can use your recpie by August 8th. After that, you&#8217;ll work with Mark and Mike to get your recipe written and included in the book!</p>
<p>If your recipe is selected, your name, bio, and a link to your site/blog will appear in the book. You&#8217;ll also receive a complimentary copy of the book, of course.</p>
<p>We look forward to working with you!</p>
<p>Mark Bates and Mike Mangino</p>
]]></content:encoded>
			<wfw:commentRss>http://www.iphonerecipesbook.com/2009/05/20/call-for-submissions-to-the-iphone-recipes-book/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
