<?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>Mark Kirby - Mobile Developer</title>
	<atom:link href="http://mark-kirby.co.uk/feed/" rel="self" type="application/rss+xml" />
	<link>http://mark-kirby.co.uk</link>
	<description>I&#039;m a user focused mobile developer, here is where I publish advice and thoughts on building great mobile apps</description>
	<lastBuildDate>Thu, 01 Mar 2012 16:56:07 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Running a local webserver from a Dropbox folder on OS X</title>
		<link>http://mark-kirby.co.uk/2012/running-a-local-webserver-from-a-dropbox-folder-on-os-x/</link>
		<comments>http://mark-kirby.co.uk/2012/running-a-local-webserver-from-a-dropbox-folder-on-os-x/#comments</comments>
		<pubDate>Mon, 20 Feb 2012 12:19:18 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=996</guid>
		<description><![CDATA[I wrote a article a few years back on setting up virtual hosts on OS X so you can have lots of urls pointing to different folders on your mac, for testing websites. A good practice I have found is to run this folder out of Dropbox, so even if you haven&#8217;t committed changes to...]]></description>
			<content:encoded><![CDATA[<p>I wrote a article a few years back on <a href="http://mark-kirby.co.uk/2008/setting-up-virtual-hosts-on-os-x-leopard/">setting up virtual hosts on OS X</a> so you can have lots of urls pointing to different folders on your mac, for testing websites. A good practice I have found is to run this folder out of Dropbox, so even if you haven&#8217;t committed changes to a remote repository your work is always saved and backed up. To do this, there are a couple of extra steps you need to take, so I am writing this article here, do read the old one first to get the basics set up, and then come here for the updates.</p>
<h2>Preparation</h2>
<p>Follow the instructions on <a href="http://mark-kirby.co.uk/2008/setting-up-virtual-hosts-on-os-x-leopard/">setting up virtual hosts on OS X</a>.</p>
<p>Your httpd-vhosts.conf should look something like this:</p>
<pre class="brush: bash; title: ; notranslate">
NameVirtualHost *:80

&lt;VirtualHost *:80&gt;
	DocumentRoot &quot;/Users/markirby/Sites&quot;
	ServerName localhost
&lt;/VirtualHost&gt;

&lt;Directory /Users/*/Sites/&gt;
    Options Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    AllowOverride All
    Order allow,deny
    Allow from all
&lt;/Directory&gt;
</pre>
<p>Make sure you have set &#8216;/private/etc/hosts&#8217;, &#8216;/private/etc/apache2/httpd.conf&#8217; and restarted apache, as per the instructions.</p>
<h2>Create a symlink to link the sites folder to dropbox</h2>
<p>Enter the following to create a symlink which will enable you to edit files in either location and have the changes backed up as you work.</p>
<pre class="brush: bash; title: ; notranslate">
ln -s ~/Sites ~/Dropbox/Sites
</pre>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2012/running-a-local-webserver-from-a-dropbox-folder-on-os-x/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to install static frameworks on Xcode 4</title>
		<link>http://mark-kirby.co.uk/2012/how-to-install-static-frameworks-on-xcode-4/</link>
		<comments>http://mark-kirby.co.uk/2012/how-to-install-static-frameworks-on-xcode-4/#comments</comments>
		<pubDate>Wed, 11 Jan 2012 13:11:33 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=971</guid>
		<description><![CDATA[I had some issues installing OCMock on Xcode 4, and found the method to be documented differently in a number of places. Fortunately I&#8217;ve worked out how to do it and it can be applied to any static framework, so I&#8217;m sharing it here, using OCMock as an example. Download the framework and locate the...]]></description>
			<content:encoded><![CDATA[<p>I had some issues installing OCMock on Xcode 4, and found the method to be documented differently in a number of places. Fortunately I&#8217;ve worked out how to do it and it can be applied to any static framework, so I&#8217;m sharing it here, using OCMock as an example.</p>
<h2>Download the framework and locate the .a and header files</h2>
<p>Download the distribution files for the framework (for OCMock it comes as a dmg) and locate the .a and header files.</p>
<p>Here&#8217;s mine on my desktop:</p>
<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-11.48.28.png"><img class="alignnone size-full wp-image-972" title="Files in desktop" src="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-11.48.28.png" alt="" width="618" height="311" /></a></p>
<h2>Copy these files into your source folder for your Xcode project</h2>
<ul>
<li>Make a subfolder in the root of your project folder named &#8216;Libraries&#8217; (or place it where you wish &#8211; I&#8217;ll refer to this as {LIBRARIES FOLDER})</li>
<li>Make a subfolder in this with the name of your Framework, e.g. OCMock &#8211; I&#8217;ll call this {FRAMEWORK FOLDER}</li>
<li>Copy the contents of your static framework in here, preserving the original folder structure</li>
</ul>
<p>When you are done your structure should look something like this:</p>
<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-03-01-at-16.43.08.png"><img class="alignnone size-full wp-image-1000" title="Screen Shot 2012-03-01 at 16.43.08" src="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-03-01-at-16.43.08.png" alt="" width="600" height="281" /></a></p>
<p>&nbsp;</p>
<h2>Create references to the files in Xcode 4</h2>
<p>To set up references to these new files:</p>
<ul>
<li>Create a new folder in Frameworks called the same as {FRAMEWORK FOLDER}</li>
<li>Drag all the files inside your actual {FRAMEWORK FOLDER} into this one</li>
<li>Deselect &#8220;Copy items to your destination folder&#8221;</li>
<li>Select the targets you need &#8211; in OCMock case it will be the Unit Tests, but generally it will be the main target</li>
</ul>
<div><a href="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-12.19.45.png"><img class="alignnone size-full wp-image-979" title="Adding framework" src="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-12.19.45.png" alt="" width="600" height="319" /></a></div>
<p>You should now see the framework listed.</p>
<p>My project folder now looks like this:</p>
<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-03-01-at-16.47.42.png"><img class="alignnone size-full wp-image-1001" title="Screen Shot 2012-03-01 at 16.47.42" src="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-03-01-at-16.47.42.png" alt="" width="260" height="293" /></a></p>
<p><em>I&#8217;ll add any more headers from other Frameworks  in subgroups with the name of the framework.</em></p>
<h2>Add your header search path to the target build settings</h2>
<ul>
<li>Select the target you added the framework for, in my case, &#8220;FrameworkInstallTests&#8221;.</li>
<li>Select the &#8220;Build Settings&#8221; tab</li>
<li>Search for &#8220;header search paths&#8221;</li>
<li>Locate &#8220;Header Search Paths&#8221; field</li>
<li>Double click the field</li>
<li>Check the &#8220;recursive&#8221; box</li>
<li>Add this to the settings:</li>
<li>$(PROJECT_DIR)/Libraries</li>
</ul>
<div><a href="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-12.56.31.png"><img class="alignnone size-full wp-image-981" title="Adding the header setting" src="http://mark-kirby.co.uk/wp-content/uploads/2012/01/Screen-Shot-2012-01-11-at-12.56.31.png" alt="" width="600" height="339" /></a></div>
<div></div>
<div><em>Note: if you didn&#8217;t place your framework files into the Libraries folder, it should point to whatever {LIBRARIES_FOLDER} is. Because you selected recursive, it will search down until it locates the headers.</em></div>
<h2>Add linker flag</h2>
<ul>
<li>Select the target you added the framework for, in my case, &#8220;FrameworkInstallTests&#8221;.</li>
<li>Select the &#8220;Build Settings&#8221; tab</li>
<li>Search for &#8220;linker flags&#8221;</li>
<li>Locate &#8220;Other Linker Flags&#8221; field</li>
<li>Double click the field</li>
<li>Add this:</li>
<li>-force_load $(PROJECT_DIR)/Libraries/{FRAMEWORK FOLDER}/{YOUR FRAMEWORK NAME}.a</li>
<li>Which should be the full path to the .a file for the framework, e.g. &#8220;$(PROJECT_DIR)/Libraries/libOCMock.a&#8221;</li>
</ul>
<h2>Restart Xcode and you should be done!</h2>
<p>Restart Xcode.</p>
<p>Leave any issues in the comments and I&#8217;ll see what I can do.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2012/how-to-install-static-frameworks-on-xcode-4/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Native vs Web with PhoneGap &#8211; which to use</title>
		<link>http://mark-kirby.co.uk/2011/native-app-vs-packaged-web-app-which-to-use/</link>
		<comments>http://mark-kirby.co.uk/2011/native-app-vs-packaged-web-app-which-to-use/#comments</comments>
		<pubDate>Tue, 13 Dec 2011 12:55:59 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=954</guid>
		<description><![CDATA[I&#8217;ve been talking to people about native vs web for years, and don&#8217;t fall down on one single answer. I thought it was time to get these thoughts down on paper. I&#8217;ve framed the discussion around a series of questions you might ask about an app you are developing. Are you designing an app which...]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been talking to people about native vs web for years, and don&#8217;t fall down on one single answer. I thought it was time to get these thoughts down on paper. I&#8217;ve framed the discussion around a series of questions you might ask about an app you are developing.</p>
<h2>Are you designing an app which could be composed of native interface elements?</h2>
<p>If you are designing an app for a phone, I would strongly consider <strong>using</strong> <strong>native UI components where possible</strong>.</p>
<ul>
<li>Native UI components provide a unified experience</li>
<li>The user should already know how to use your app as it features recognisable interface elements</li>
<li>Time spent redesigning existing components is time that could be spent better on the overall experience and areas that really are specific to your domain</li>
</ul>
<p><a href="http://itunes.apple.com/us/app/metar-reader/id465765574?mt=8">METAR reader for iPhone</a> was built as a packaged web app, and does not use standard UI elements.</p>
<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2011/12/mzl.epwurhsn.jpeg"><img class="alignnone size-medium wp-image-955" title="mzl.epwurhsn" src="http://mark-kirby.co.uk/wp-content/uploads/2011/12/mzl.epwurhsn-200x300.jpg" alt="" width="200" height="300" /></a></p>
<p>It looks very nice, it could be for Android as much as iPhone, but could also easily be created using well styled native UI elements which would make it easier for users to know what to do and give the app a more familiar feel. What are those bottom 3 tabs for?</p>
<p>Some apps don&#8217;t really need to use native interface elements&#8230;</p>
<h2>Apps with neutral designs</h2>
<p>If you are designing a tablet app you may find yourself designing something which is neutral, more like a website, which doesn&#8217;t use native UI components. On tablet devices apps tend to follow less of a standard UI look, so there is less consistency anyway.</p>
<p>The <a href="http://apps.ft.com/ftwebapp/">FT web app</a> looks the same on all devices, and doesn&#8217;t lend itself to using native UI elements.</p>
<p><img class="alignnone size-medium wp-image-961" title="FT-app" src="http://mark-kirby.co.uk/wp-content/uploads/2011/12/FT-app-300x205.jpg" alt="" width="300" height="205" /></p>
<p>This app can look like this on any device, it uses no common interface elements.</p>
<h2>Recreating native interface elements with web technologies is a bad idea</h2>
<p>Recreating standard UI components in web can lead to the &#8216;<strong>uncanny valley</strong>&#8216; effect, where the app looks native but doesn&#8217;t feel quite right, as <a href="http://hackerne.ws/item?id=2982224">this discussion</a> describes.</p>
<p>At the moment you will never get a PhoneGap app with fake UI elements working as well as a native app with real UI components. There is an unobtainable final 5% of performance that can&#8217;t be gained.</p>
<p>A <strong>native app</strong> can work as well any on the device and <strong>feels solid and well produced</strong>.</p>
<h2>Native interface elements differ between platforms</h2>
<p>Each platform has a different standard look and feel.</p>
<p>Facebook on iPhone:</p>
<p><img class="alignnone size-medium wp-image-962" title="facebook-for-iphone-13" src="http://mark-kirby.co.uk/wp-content/uploads/2011/12/facebook-for-iphone-13-200x300.jpg" alt="" width="200" height="300" /></p>
<p>Facebook on Android:</p>
<p><img class="alignnone size-medium wp-image-963" title="Foreman_11657656_1024_38814_424516450908_74769995908_4660025_5606091_n_257x380" src="http://mark-kirby.co.uk/wp-content/uploads/2011/12/Foreman_11657656_1024_38814_424516450908_74769995908_4660025_5606091_n_257x380-202x300.jpg" alt="" width="202" height="300" /></p>
<p>Facebook on Windows Phone:</p>
<p><img class="alignnone size-medium wp-image-964" title="Facebook-Windows-Phone-7" src="http://mark-kirby.co.uk/wp-content/uploads/2011/12/Facebook-Windows-Phone-7-189x300.jpg" alt="" width="189" height="300" /></p>
<p>Each version of the app is consistent with the platform running it, and facebook lends itself to this. You certainly couldn&#8217;t put the iPhone design onto an Android device without it looking fake.</p>
<p>If you want to develop an app with a consistent UI on the platform running it (and in most cases you should), you need to <strong>redesign the app for every platform</strong>.</p>
<p>There will therefore be <strong>additional CSS work to do on every platform</strong> you want the app to run on, but with web you can share the core code. Even if you don&#8217;t redesign the app for other devices, browser differences mean you may have inconsistencies which will need to be tested for and worked out.</p>
<h2>Neutral designs work well as packaged web apps</h2>
<p>If your app doesn&#8217;t contain any native UI elements (like the FT app) it can easily be produced with web technologies without feeling fake.</p>
<p>The user has no expectations related to the UI elements you are using, so performance issues are reduced.</p>
<p>It will be easier to create custom UI elements with web technologies than using native tools to do so, so the project can be delivered quicker.</p>
<p>No redesign will be needed when putting the app on other devices, so minimal effort will be needed to target multiple platforms.</p>
<h2>To conclude&#8230;</h2>
<p>Don&#8217;t recreate native experiences with packaged web apps.</p>
<p>Use packaged web apps to create platform neutral experiences that can run across many platforms, none of which resemble the native experience on any single platform.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/native-app-vs-packaged-web-app-which-to-use/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Full Frontal Conference 2011 review</title>
		<link>http://mark-kirby.co.uk/2011/full-frontal-conference-2011-review/</link>
		<comments>http://mark-kirby.co.uk/2011/full-frontal-conference-2011-review/#comments</comments>
		<pubDate>Sun, 13 Nov 2011 18:11:15 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>
		<category><![CDATA[fullfrontalconf]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=927</guid>
		<description><![CDATA[Last Friday I attended Full Frontal 2011, which turned out to be the best conference I&#8217;ve attended so far.  Some rights reserved by Remy Sharp For the first time in 5 years of conference going I had no complaints whatsoever. I am often irritated by excessive promotion of products by sponsors, talks which are really little more...]]></description>
			<content:encoded><![CDATA[<p>Last Friday I attended Full Frontal 2011, which turned out to be the best conference I&#8217;ve attended so far.</p>
<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2011/11/6283388978_08f3ef14da_z.jpeg"><img class="alignnone size-full wp-image-931" title="Full Frontal" src="http://mark-kirby.co.uk/wp-content/uploads/2011/11/6283388978_08f3ef14da_z.jpeg" alt="" width="428" height="428" /></a></p>
<p><a href="http://creativecommons.org/licenses/by-sa/2.0/"><img title="Attribution" src="http://l.yimg.com/g/images/cc_icon_attribution_small.gif" alt="Attribution" border="0" /><img title="Share Alike" src="http://l.yimg.com/g/images/cc_icon_sharealike_small.gif" alt="Share Alike" border="0" /></a> <a title="Attribution-ShareAlike License" href="http://creativecommons.org/licenses/by-sa/2.0/">Some rights reserved</a> by <a href="http://www.flickr.com/photos/remysharp/">Remy Sharp</a></p>
<p>For the first time in 5 years of conference going I had no complaints whatsoever. I am often irritated by excessive promotion of products by sponsors, talks which are really little more than product placement, poor quality speakers and a host of other minor niggles which reduce the quality of an otherwise great event. At Full Frontal, this year (I attended the first, which whilst still good, wasn&#8217;t quite up to this years standard), I had no such problems. Instead I enjoyed a stream of high quality professional speakers discussing a range of topics at various levels of complexity.</p>
<p>First up we had <a href="http://ashkenas.com/">Jeremy Ashkenas</a>, one time creator of Underscore, Backbone and now <a href="http://jashkenas.github.com/coffee-script/">Coffeescript</a>, give an overview of what Coffeescript is (write JavaScript in another language, which compiles to pure JavaScript). Like a few others I spoke to, I have some serious issues with using Coffeescript for projects where I&#8217;ll be handing to code over to others, but as Jeremy explained, it makes writing JavaScript simpler and more logical, which could be fun to try on a personal project.</p>
<p>One of the days highlights came next, <a href="http://hawksworx.com/">Phil Hawksworth</a>, who delivered one of the best talks I&#8217;ve seen in terms of pacing, humour and keeping a high level of engagement. Phil implored us to not use HTML5 as an excuse to return to the long loading screens and inaccessibility of Flash in its shitty heyday. Just because we can, shouldn&#8217;t mean me should, and I couldn&#8217;t agree more. There is a fashion appearing at the moment for huge single page sites with mock navigation, no urls and no non-javascript support, and like Phil, I hope these don&#8217;t become common place and we see a return to standards based websites which use not abuse the new techniques available to us.</p>
<p>Two talks about coding within the browser by Marijn Haverbeke and Rik Arends have made me decide to investigate the <a href="http://c9.io/">cloud 9</a> online IDE further. If any talk came close to product placement today it would be Rik&#8217;s, but rather than irritate me, he managed to tread the line between salesman and technical guy carefully enough to keep my interest.</p>
<p>I learned the most today from Yahoo&#8217;s <a href="http://www.nczonline.net/">Nicholas Zakas</a> who nailed exactly how to structure a large-scale JavaScript application with his talk on <a href="http://www.slideshare.net/nzakas/scalable-javascript-application-architecture">Scalable JavaScript Application Architecture</a>. I am already structuring code in a way that is close to how he described, but not quite close enough for my liking. It felt like he pushed me that last step to total clarity, and I&#8217;ll certainly be writing more about this in the coming months.</p>
<p>Prize for the most passionate hacker of the day goes to <a href="http://www.glennjones.net/">Glenn Jones</a>, whose <a href="http://glennjones.net/2011/11/beyond-the-page-fullfrontal-2011/">demos around Microformats and drag and drop</a> showed what should already be mainstream. It was inspiring to see someone thinking outside of what is obviously possible and pushing the boundaries. <a href="http://www.aresluna.org/">Marcin Wichary</a>, the creator of interactions on many of google&#8217;s doodles also showed us how to make the impossible achievable, simply by thinking about problems in different ways. Browser limitations mean his code may not be &#8216;perfect&#8217; and totally clean, but he makes things that work, and they go on the Google homepage.</p>
<p>I&#8217;ve never been a big fan of the kind of sites <a href="http://www.brendandawes.com/">Brendan Dawes</a> and his team creates, but I&#8217;m glad they exist. He took us through the thought process that leads to the creation of these exploratory sites, and proved that what works for one person may not work for others. I prefer simple clear navigation, but I don&#8217;t tend to stay long on sites. There are multiple use cases, and Brendan showed us this.</p>
<p>A great day, thanks to all who helped make it happen!</p>
<p>#fullfrontalconf</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/full-frontal-conference-2011-review/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Tools used to create a complex JavaScript app &#8211; notes for an Async mini talk</title>
		<link>http://mark-kirby.co.uk/2011/tools-used-to-create-a-complex-javascript-app-notes-for-an-async-mini-talk/</link>
		<comments>http://mark-kirby.co.uk/2011/tools-used-to-create-a-complex-javascript-app-notes-for-an-async-mini-talk/#comments</comments>
		<pubDate>Thu, 10 Nov 2011 13:01:49 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=923</guid>
		<description><![CDATA[I&#8217;ve spent the last 6 months leading the team who worked with Tesco on the development of the Tesco Food app in the Chrome Web Store. If there is time I hope to give a quick 5 min talk at Brighton&#8217;s Async group for the International Show and Tell this week, these are the notes...]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve spent the last 6 months leading the team who worked with Tesco on the development of the <a href="https://chrome.google.com/webstore/detail/ffibhmnkceoelgabpnpaaojflglampjb">Tesco Food app</a> in the Chrome Web Store. If there is time I hope to give a quick 5 min talk at Brighton&#8217;s Async group for the <a href="http://asyncjs.com/international2011/">International Show and Tell</a> this week, these are the notes for that talk.</p>
<h2><a href="https://chrome.google.com/webstore/detail/ffibhmnkceoelgabpnpaaojflglampjb">Tesco Food App, Chrome Web Store</a></h2>
<ul>
<li>Large shopping app</li>
<li>All local</li>
<li>JS, HTML, CSS</li>
</ul>
<h2><a href="http://documentcloud.github.com/backbone/">Backbone</a></h2>
<ul>
<li>Models, collections, structure, underscore wrapped</li>
<li>Combined with an MVC approach</li>
<li>Didn&#8217;t take advantage of most, could be done differently</li>
</ul>
<h2><a href="http://api.jquery.com/category/plugins/templates/">jQuery templates</a> for templating</h2>
<ul>
<li>HTML, so easy to follow</li>
<li>Limited documentation and hard to debug</li>
<li>No longer supported</li>
<li>Used AJAX to load multiple templates in after launching the app, would not recommend &#8211; can be slow and needlessly complex</li>
</ul>
<h2><a href="http://seleniumhq.org/">Selenium</a> for automated browser testing</h2>
<ul>
<li>reduce the amount of mundane user testing</li>
<li>steep learning curve</li>
<li>code needs to be as structured as main (almost)</li>
<li>don&#8217;t change versions during a project</li>
</ul>
<h2><a href="http://enterprisejquery.com/2010/07/mock-your-ajax-requests-with-mockjax-for-rapid-development/">jQuery Mockjax</a> for mocking data</h2>
<ul>
<li>jQuery plugin, intercepting jQuery AJAX calls</li>
<li>flexible &#8211; allows for most scenarios with a little work</li>
<li>minimal contact with app &#8211; load it once and it takes over</li>
</ul>
<h2>Build script with <a href="http://rake.rubyforge.org/">Rake</a></h2>
<ul>
<li>Concatenation with <a href="https://github.com/sstephenson/sprockets">sprockets</a> require</li>
<li><a href="http://code.google.com/p/jslint4java/">jsLint4java</a> for syntax checking &#8211; use strict to get team code consistency</li>
<li><a href="http://developer.yahoo.com/yui/compressor/">YUI Compressor</a> for minification</li>
</ul>
<h2>Wish I&#8217;d used <a href="http://code.google.com/closure/compiler/">Google closure compiler</a></h2>
<ul>
<li>Uses docs to check type, static etc</li>
<li>Removes code you don&#8217;t use</li>
<li>Can make mistakes/cause issues under documented circumstances</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/tools-used-to-create-a-complex-javascript-app-notes-for-an-async-mini-talk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The developer&#8217;s manifesto</title>
		<link>http://mark-kirby.co.uk/2011/the-developers-manifesto/</link>
		<comments>http://mark-kirby.co.uk/2011/the-developers-manifesto/#comments</comments>
		<pubDate>Mon, 31 Oct 2011 09:50:36 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=865</guid>
		<description><![CDATA[The developers manifesto I&#8217;ve created here are a set of coding guidelines that me and the development team I work with believe will lead to high quality, easily readable code. Code written not for you to read, but for someone else to read. It is the result of several weeks of meetings, reading a number...]]></description>
			<content:encoded><![CDATA[<p>The developers manifesto I&#8217;ve created here are a set of coding guidelines that me and the <a href="http://ribot.co.uk">development team I work with</a> believe will lead to high quality, easily readable code. Code written not for you to read, but for someone else to read. It is the result of several weeks of meetings, reading a number of books, and years of making these mistakes. I am publishing it here first so the team have an online resource to refer to, and to inspire others to create great code also.</p>
<h2>Indentation, brackets and spaces</h2>
<p><em>We have selected the following standards, but what matters most is not which standard, but that you have a standard. We will use this convention on all new projects. On existing projects, stick with the previously established convention.</em></p>
<p>Use<strong> 4 spaces, soft tabs</strong> (so really uses spaces, not&nbsp;tabs when you press the tab key) unless the language requires otherwise.&nbsp;<a href="http://www.codinghorror.com/blog/2009/04/death-to-the-space-infidels.html">More over on coding horror&#8230;</a></p>
<p>Use <strong>brackets on the same line</strong></p>
<pre class="brush: jscript; highlight: [1,2,4,6]; title: ; notranslate">
function functionName() {
	if (shouldDoSomething) {
		doSomething();
	} else {
		doNotDoAnything();
	}
}
</pre>
<p>Add <strong>1 space between brackets and braces</strong></p>
<pre class="brush: jscript; title: ; notranslate">
function functionName() {
	if (shouldDoSomething) {
</pre>
<p>Add <strong>1 space between operators</strong></p>
<pre class="brush: jscript; title: ; notranslate">
var concatenatedString = string1 + string2 + &quot;.&quot;;
</pre>
<h2>Use meaningful names</h2>
<p>Use meaningful names for variables, functions and classes,&nbsp;select names which describe exactly what the variable, function or class does</p>
<ul>
<li><strong>No abbreviations</strong> except common ones to be listed here as found</li>
<li><strong>No single character variables</strong> except in loops</li>
<li><strong>No hungarian notation</strong> (including data types inside variable names)</li>
<li><strong>No acronyms </strong>use full names</li>
<li>Classes are nouns, methods verbs</li>
</ul>
<p>So this :</p>
<pre class="brush: jscript; title: ; notranslate">
function name(b, c) {
    strName = b + &quot; &quot; + c;
}
</pre>
<p>becomes:</p>
<pre class="brush: jscript; title: ; notranslate">
function setName(firstName, lastName) {
    name = firstName + &quot; &quot; + lastName;
}
</pre>
<h2>Use consistent names</h2>
<p>Define these patterns at the start of the project</p>
<ul>
<li>Is it a manager or a controller</li>
<li>Is it fetch or get</li>
</ul>
<h2>Functions and classes</h2>
<ul>
<li>Functions do only one thing, and the name of the function must clearly identify that thing</li>
<li>Functions should have no side effects, so a function named checkPassword should not also initialise a session</li>
<li>Functions ideally be no more than 4 lines, certainly no more than 8</li>
<li>Functions can have no more than one level of indentation</li>
<li>Functions must work at one level of abstraction, either calling other functions, or performing a single action low level code, such as manipulating a string</li>
<li>Classes have a single area of responsibility and are as small as possible</li>
<li>Don&#8217;t pass arguments to functions in a class except to alter and return them, or ask a question about them. Instead modify class instance variables</li>
<li>Don&#8217;t pass true or false flags to arguments, instead call different functions</li>
<li>Where you must pass an argument to a function pass only one or two arguments. Three suggests you need to create a new class</li>
</ul>
<h3>Structure of classes</h3>
<p>Classes should be laid out thus:</p>
<ol>
<li>public static constants</li>
<li>private static constants</li>
<li>private instance variables</li>
<li>overridden functions</li>
<li>public/private functions, ordered in layers as they are used so used functions are as close as possible to the function calling it (see levels in code example below)</li>
</ol>
<p><em>These are controversial, but after trying them, we find code is more readable.</em></p>
<p>Before:</p>
<pre class="brush: jscript; title: ; notranslate">
var splash = (function() {

    var
    _shouldAutomaticallyChange = true,
    _numberOfSlides = 0,

    _getPositionOfCurrentSlide = function() {
        var slidesArray = _getSlidesAsArray();
        var i = slidesArray.length - 1;
        for (i; i &gt;= 0; i--) {
            if (jQuery(slidesArray[i]).hasClass(&quot;current&quot;)) {
                return i + 1;
            }
        }
        return false;
    },

    _getPositionOfNextSlide = function(currentSlide, numberOfSlides) {
        if (currentSlide === numberOfSlides) {
            return 1;
        } else {
            return currentSlide + 1;
        }
    },

    _getPositionOfPreviousSlide = function(currentSlide, numberOfSlides) {
        if (currentSlide === 1) {
            return numberOfSlides;
        } else {
            return currentSlide - 1;
        }
    },

    _changeSlide = function(from, to) {
        if (from !== to) {
            jQuery('#splash-tabs &gt; li:nth-child('+from+')').removeClass('current');
            jQuery('#splash-tabs &gt; li:nth-child('+to+')').addClass('current');
            jQuery('.splash'+from).fadeOut('slow').removeClass('current');
            jQuery('.splash'+to).fadeIn('slow').addClass('current');

        }
    },

    _getSlidesAsArray = function() {
        return jQuery(&quot;#splash-tabs &gt; li&quot;);
    },

    _onClickNext = function() {
        var currentSlide = _getPositionOfCurrentSlide();
        _changeSlide(currentSlide, _getPositionOfNextSlide(currentSlide, _numberOfSlides));
    },

    _onClickPrevious = function() {
        var currentSlide = _getPositionOfCurrentSlide();
        _changeSlide(currentSlide, _getPositionOfPreviousSlide(currentSlide, _numberOfSlides));
    },

    _changeIfShouldChange = function() {
        if (_shouldAutomaticallyChange) {
            setTimeout(_change, 6000);
        }
    },

    _change = function() {
       if (_shouldAutomaticallyChange) {
          _onClickNext();
          _changeIfShouldChange();
       }
    };

    init = function() {

        _numberOfSlides = _getSlidesAsArray().length;

        jQuery(&quot;#splash .next&quot;).bind('click', function() {
            _shouldAutomaticallyChange = false;
            _onClickNext();
        });

        jQuery(&quot;#splash .previous&quot;).bind('click', function() {
            _shouldAutomaticallyChange = false;
            _onClickPrevious();
        });

        jQuery(&quot;#splash .next&quot;).bind('touchstart', function() {
            jQuery(this).addClass('active');
        });
        jQuery(&quot;#splash .next&quot;).bind('touchend', function() {
            jQuery(this).removeClass('active');
        });

        jQuery(&quot;#splash .previous&quot;).bind('touchstart', function() {
            jQuery(this).addClass('active');
        });
        jQuery(&quot;#splash .previous&quot;).bind('touchend', function() {
            jQuery(this).removeClass('active');
        });

        jQuery('#splash-tabs &gt; li').bind('click', function() {
            _shouldAutomaticallyChange = false;
            var currentSlide = _getPositionOfCurrentSlide();
            var position = _numberOfSlides - jQuery(this).nextAll().length;
            _changeSlide(currentSlide, position);
        });

    };

   return {
      init: init
   }

}());
</pre>
<p>After:</p>
<pre class="brush: jscript; title: ; notranslate">
var splash = (function() {

    var
    _NUMBER_OF_SLIDES,

    _shouldAutomaticallyChange = true,
    _postionOfCurrentSlide = 1,

    init = function(automate) {
        _NUMBER_OF_SLIDES = _countNumberOfTabs();

        jQuery(&quot;#splash .next&quot;).bind('click', _onClickNext);
        jQuery(&quot;#splash .previous&quot;).bind('click', _onClickPrevious);
        jQuery('#splash-tabs &gt; li').bind('click', _onClickTab);

        jQuery(&quot;#splash .next&quot;).bind('touchstart', _onTouchStartButton);
        jQuery(&quot;#splash .next&quot;).bind('touchend', _onTouchEndButton);

        jQuery(&quot;#splash .previous&quot;).bind('touchstart', _onTouchStartButton);
        jQuery(&quot;#splash .previous&quot;).bind('touchend', _onTouchEndButton);

        if (automate) {
           _triggerDelayedCallToGoToNextSlideAutomatically();
        }
    },

    //Level 1

    _onClickNext = function() {
        _preventSlidesFromAutomaticallyChanging();
        _goToNextSlide();
    },
    _onClickPrevious = function() {
        _preventSlidesFromAutomaticallyChanging();
        _goToPreviousSlide();
    },
    _onClickTab = function() {
        var positionOfClickedTab = _numberOfSlides - jQuery(this).nextAll().length;
        _preventSlidesFromAutomaticallyChanging();
        _changeSlide(positionOfClickedTab);
    },

    _onTouchStartButton = function() {
        jQuery(this).addClass('active');
    },
    _onTouchEndButton = function() {
        jQuery(this).removeClass('active');
    },

    /**
       @return {number}
    */
    _countNumberOfTabs = function() {
        return jQuery(&quot;#splash-tabs &gt; li&quot;).length;
    },
    _triggerDelayedCallToGoToNextSlideAutomatically = function() {
        if (_shouldAutomaticallyChange) {
            setTimeout(_goToNextSlideAutomatically, 6000);
        }
    },

    //Level 2
    _preventSlidesFromAutomaticallyChanging = function() {
        _shouldAutomaticallyChange = false;
    },
    _goToNextSlide = function() {
        _changeSlide(_getPositionOfNextSlide());
    },
    _goToPreviousSlide = function() {
        _changeSlide(_getPositionOfPreviousSlide());
    },
    _goToNextSlideAutomatically = function() {
        if (_shouldAutomaticallyChange) {
            _goToNextSlide();
            _triggerDelayedCallToGoToNextSlideAutomatically();
        }
    },

    //Level 3
    _getPositionOfNextSlide = function() {
        if (_postionOfCurrentSlide === _numberOfSlides) {
            return 1;
        } else {
            return _postionOfCurrentSlide + 1;
        }
    },
    _getPositionOfPreviousSlide = function() {
        if (_postionOfCurrentSlide === 1) {
            return _numberOfSlides;
        } else {
            return _postionOfCurrentSlide - 1;
        }
    },
    _changeSlide = function(postionToChangeTo) {
        if (_postionOfCurrentSlide !== postionToChangeTo) {
            jQuery('#splash-tabs &gt; li:nth-child(' + _postionOfCurrentSlide + ')').removeClass('current');
            jQuery('#splash-tabs &gt; li:nth-child(' + postionToChangeTo + ')').addClass('current');
            jQuery('.splash' + _postionOfCurrentSlide).fadeOut('slow').removeClass('current');
            jQuery('.splash' + postionToChangeTo).fadeIn('slow').addClass('current');
            _postionOfCurrentSlide = postionToChangeTo;
        }
    };

    return {
        init: init
    };

}());
</pre>
<h2>Comments</h2>
<ul>
<li>Comments should not be needed except to document var and argument types in Javascript</li>
<li>Instead of comments use smaller, better named functions</li>
<li>A doc system such as JavaDoc should not require you to duplicate any information, e.g. functions should only be named in the code, not repeated in doc notation</li>
<li>Never commit commented out code</li>
</ul>
<h2>Testing</h2>
<p>We write code with full unit testing and integration/automated user testing (using tools such as Selenium to mock user input)</p>
<h2>Repository management</h2>
<p>We use git</p>
<h2>Code reviews</h2>
<p>All code pushed to the main development branch is reviewed by another team member, checking all of the points listed here and making sure code is readable and makes sense</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/the-developers-manifesto/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Mobile context</title>
		<link>http://mark-kirby.co.uk/2011/the-mobile-context/</link>
		<comments>http://mark-kirby.co.uk/2011/the-mobile-context/#comments</comments>
		<pubDate>Thu, 24 Feb 2011 11:02:14 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=849</guid>
		<description><![CDATA[The mobile context is being discussed a great deal at the moment in regards to mobile web. What does it mean? How can we use it? How can we make assumptions about the context a user is in, based on their device? To give a few examples of assumed mobile contexts, and ways sites might...]]></description>
			<content:encoded><![CDATA[<p>The mobile context is being discussed a great deal at the moment in regards to mobile web. What does it mean? How can we use it? How can we make assumptions about the context a user is in, based on their device?</p>
<p><a href="http://www.flickr.com/photos/sansharma/4025098447/"><img class="alignnone size-full wp-image-856" title="IMG_2928" src="http://mark-kirby.co.uk/wp-content/uploads/2011/02/4025098447_59668094b3.jpeg" alt="" width="500" height="333" /></a></p>
<p>To give a few examples of assumed mobile contexts, and ways sites might work around them:</p>
<ul>
<li>I&#8217;m an airline, my user is on a mobile, they must be checking in, I&#8217;ll remove access to booking and focus on check in features</li>
<li>I&#8217;m a shop, user on a mobile, they must be looking for a store, I&#8217;ll serve up the address and a map and remove access to the shop</li>
<li>I&#8217;m a newspaper, user on a mobile, they must be on the move, only want to know the top 3 stories</li>
</ul>
<p>Perhaps the user was not in those contexts, they were at home, booking a flight, online shopping or wanting to read the local news. On their mobile, in front of the tv or perhaps in bed. <a href="http://thefonecast.com/News/tabid/62/EntryId/3602/Mobile-shopping-is-popular-when-watching-TV-says-Orange-UK-research.aspx">Research showing how large a percentage of people use the mobile web at home has been done</a>, lets not ignore this key fact.</p>
<h2>The number one crime in the name of mobile context</h2>
<p>A number of sites have taken to serving up different mobile content, and allowing <strong>no access</strong> to the remaining content on the site. Some even redirect users to a mobile site from any link, rendering urls you may want to use inaccessible.</p>
<p>This leads to a broken web, on mobile.</p>
<h2>The download speed argument</h2>
<p>One main argument for reducing content on mobile is that the download speed is less, or bandwidth is more limited.</p>
<p>I often use my mobile at work and home to browse sites. I am sure I&#8217;m not the only one.</p>
<p>I also often use my desktop in hotels and with a dongle.</p>
<p><strong>Mobile != low download speed</strong></p>
<h2>Other ways of guessing context</h2>
<p>Recently I&#8217;ve heard suggestions of other, harder to measure ways of guessing context.</p>
<ul>
<li>Detecting location using GPS</li>
<li>Detecting motion using GPS</li>
<li>Detecting download/connection</li>
</ul>
<p>These are harder to measure, and still don&#8217;t accurately confirm context. If it were possible to accurately know the context the user is in, we still have a problem.</p>
<h2>Context != intent</h2>
<p>I&#8217;m definitely moving, I&#8217;m definitely in a car. I&#8217;m going to look at your website.</p>
<p>This <em>still</em> doesn&#8217;t mean my intent is to find an address, or quickly use a news site and check the most popular stories. Context can&#8217;t predict the way a user is going to use the site.</p>
<p><strong>Mind reading is no way to base fundamental content decisions</strong></p>
<h2>So what can you be sure of?</h2>
<p>You can be sure the user has a smaller screen. Content may need rearranging, using techniques such as <a href="http://www.alistapart.com/articles/responsive-web-design/">Responsive Web Design</a>.</p>
<p>Content may need to be somewhat repurposed or refocused. This should relate to the priority you set things in on the desktop.</p>
<p>Low priority items may need to be removed. Examples include:</p>
<ul>
<li>Duplicate navigation</li>
<li>Large adverts</li>
<li>Superfluous imagery</li>
<li>Large interactive features</li>
</ul>
<p>You may wish to give higher priority to certain features <strong>research</strong> has shown people are more likely to need when on a small mobile device (your own research, into <strong>your</strong> users).</p>
<h2>My guidelines to safely changing sites based on device:</h2>
<ul>
<li>All urls should resolve and present the core content available on that page to any device</li>
<li>That&#8217;s it really!</li>
</ul>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/the-mobile-context/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>The Oscars Project</title>
		<link>http://mark-kirby.co.uk/2011/the-oscars-project/</link>
		<comments>http://mark-kirby.co.uk/2011/the-oscars-project/#comments</comments>
		<pubDate>Sat, 15 Jan 2011 15:35:29 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=841</guid>
		<description><![CDATA[Something a little different today. I wanted to let you know about a new blog I&#8217;ve started, The Oscars Project, where I&#8217;m watching and reviewing all the best picture winners. For a while now I&#8217;ve decided I haven&#8217;t seen enough older films from the last 100 years, and so to give my plan to see...]]></description>
			<content:encoded><![CDATA[<p><a href="http://mark-kirby.co.uk/wp-content/uploads/2011/01/00015297.jpeg"><img class="alignnone size-full wp-image-842" title="00015297" src="http://mark-kirby.co.uk/wp-content/uploads/2011/01/00015297.jpeg" alt="" width="399" height="281" /></a></p>
<p>Something a little different today. I wanted to let you know about a new blog I&#8217;ve started, The Oscars Project, where I&#8217;m watching and reviewing all the <a href="http://theoscarsproject.com/best-picture-winners">best picture winners</a>. For a while now I&#8217;ve decided I haven&#8217;t seen enough older films from the last 100 years, and so to give my plan to see more a direction, I decided to watch ever winner of the best picture oscar since 1928 when they began.</p>
<p>So far I&#8217;ve seen 4 films, but I&#8217;ll be adding a new one every few days as I work my way through them. Once I&#8217;m done I plan to move on to watch all the Palme d&#8217;Or winners, Golden Lion winners and possibly even the AFI top 250 films of all time. Anyway the blog is up and running at <a href="http://theoscarsproject.com">theoscarsproject.com</a> so check it out if you fancy some recommendations of classics.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/the-oscars-project/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Auto TinySrc WordPress Plugin</title>
		<link>http://mark-kirby.co.uk/2011/auto-tinysrc-wordpress-plugin/</link>
		<comments>http://mark-kirby.co.uk/2011/auto-tinysrc-wordpress-plugin/#comments</comments>
		<pubDate>Wed, 12 Jan 2011 17:53:52 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=825</guid>
		<description><![CDATA[Download and learn how to use our new plugin, enabling all WordPress sites to automatically use TinySrc to optimise all images for mobile.]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve published a new WordPress plugin which I wrote for Ribot today, enabling anyone to use TinySrc on their site by simply adding it. <a href="http://wordpress.org/extend/plugins/auto-tinysrc/">Download it from WordPress.org.</a></p>
<p><a href="http://tinysrc.net/">TinySrc</a> is a service provided by Sencha which dynamically shrinks your images according to the device accessing them. This helps shrink images for mobile, and will cut down the size of a site with <a href="http://www.alistapart.com/articles/responsive-web-design/">a responsive design</a>.</p>
<p>This plugin replaces all image tag src&#8217;s within your content with the tinysrc src (http://mysite.com/myimage.png becomes http://i.tinysrc.mobi/http://mysite.com/myimage.png), and provides a function to call in your themes to optimise those images.</p>
<p>To use the plugin, run through the following:</p>
<p>1. Upload `auto-tinysrc.php` to the `/wp-content/plugins/` directory</p>
<p>2. Activate the plugin through the &#8216;Plugins&#8217; menu in WordPress</p>
<p>3. Place</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="sy0">&lt;!&#8211;</span>?php<span class="sy0">&lt;</span>br <span class="sy0">/&#8211;&gt;</span> <span class="kw1">if</span> <span class="br0">&#40;</span><a href="http://www.php.net/function_exists"><span class="kw3">function_exists</span></a><span class="br0">&#40;</span><span class="st_h">&#8216;get_tinysrc_image&#8217;</span><span class="br0">&#41;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
get_tinysrc_image<span class="br0">&#40;</span><span class="st_h">&#8216;image_url&#8217;</span><span class="br0">&#41;</span><span class="sy0">;</span><br />
<span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
<span class="kw1">echo</span> image_url<span class="sy0">;</span><br />
<span class="br0">&#125;</span> ?<span class="sy0">&amp;</span>gt<span class="sy0">;</span></div>
</div>
<p>in your templates to display any template images optimised, e.g.</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="sy0">&lt;!&#8211;</span>?php<span class="sy0">&lt;</span>br <span class="sy0">/&#8211;&gt;</span> <span class="re0">$image_url</span> <span class="sy0">=</span> get_bloginfo<span class="br0">&#40;</span><span class="st_h">&#8216;template_url&#8217;</span><span class="br0">&#41;</span><span class="sy0">.</span><span class="st_h">&#8216;/images/bonsai_404_error.png&#8217;</span><span class="sy0">;</span><br />
<span class="kw1">if</span> <span class="br0">&#40;</span><a href="http://www.php.net/function_exists"><span class="kw3">function_exists</span></a><span class="br0">&#40;</span><span class="st_h">&#8216;get_tinysrc_image&#8217;</span><span class="br0">&#41;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span><br />
get_tinysrc_image<span class="br0">&#40;</span><span class="re0">$image_url</span><span class="br0">&#41;</span><span class="sy0">;</span><br />
<span class="br0">&#125;</span> <span class="kw1">else</span> <span class="br0">&#123;</span><br />
<span class="kw1">echo</span> <span class="re0">$image_url</span><span class="sy0">;</span><br />
<span class="br0">&#125;</span> ?<span class="sy0">&amp;</span>gt<span class="sy0">;</span></div>
</div>
<p>4. To get a variable containing the url of an image with the tinysrc url use</p>
<div class="codesnip-container" >
<div class="php codesnip" style="font-family:monospace;"><span class="sy0">&lt;!&#8211;</span>?php<span class="sy0">&lt;</span>br <span class="sy0">/&#8211;&gt;</span> <span class="kw1">if</span> <span class="br0">&#40;</span><a href="http://www.php.net/function_exists"><span class="kw3">function_exists</span></a><span class="br0">&#40;</span><span class="st_h">&#8216;get_tinysrc_image&#8217;</span><span class="br0">&#41;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span> &nbsp; &nbsp;get_tinysrc_image<span class="br0">&#40;</span>get_bloginfo<span class="br0">&#40;</span><span class="st_h">&#8216;template_url&#8217;</span><span class="br0">&#41;</span><span class="sy0">.</span><span class="st_h">&#8216;/images/bonsai_404_error.png&#8217;</span><span class="sy0">,</span> <span class="kw4">false</span><span class="br0">&#41;</span><span class="sy0">;</span><br />
<span class="br0">&#125;</span> ?<span class="sy0">&amp;</span>gt<span class="sy0">;</span></div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2011/auto-tinysrc-wordpress-plugin/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>2010 in a nutshell</title>
		<link>http://mark-kirby.co.uk/2010/2010-in-a-nutshell/</link>
		<comments>http://mark-kirby.co.uk/2010/2010-in-a-nutshell/#comments</comments>
		<pubDate>Sat, 18 Dec 2010 12:44:44 +0000</pubDate>
		<dc:creator>kirby.mark</dc:creator>
				<category><![CDATA[post]]></category>

		<guid isPermaLink="false">http://mark-kirby.co.uk/?p=823</guid>
		<description><![CDATA[Its that time of year where I like to look back and summarise what I&#8217;ve done, ready for the new years plans. So in 2010&#8230; I lead development for Ribot on the Tesco Grocery App for Nokia which allows customers to shop from their phones, released back in the summer. I had 2 articles published...]]></description>
			<content:encoded><![CDATA[<p>Its that time of year where I like to look back and summarise what I&#8217;ve done, ready for the new years plans. So in 2010&#8230;</p>
<ul>
<li>I lead development for <a href="http://ribot.co.uk/">Ribot</a> on the <a href="http://www.tesco.com/apps/nokia/">Tesco Grocery App for Nokia</a> which allows customers to shop from their phones, <a href="http://www.computing.co.uk/ctg/news/1830115/tesco-launches-nokia-application">released back in the summer</a>.</li>
<li>I had 2 articles published for <a href="http://www.netmag.co.uk/">.net magazine</a> &#8211; a PhoneGap tutorial and an opinion piece on Responsive Web Design (expect to hear a lot more on that subject in the new year!).</li>
<li>I gave a well subscribed <a href="http://asyncjs.com/phonegap/">talk on PhoneGap</a> at a local JavaScript user group, asyncjs</li>
<li>We grew the development team at Ribot, and were lucky enough to snag <a href="http://jasonfry.co.uk/">Jason Fry</a> &#8211; an Android developer in high demand.</li>
<li>I popped along to the fantastic <a href="http://mlove.com/">mlove festival in Germany</a>, something to look out for next year</li>
<li>The rest of the time I worked on some secret projects, one of which will be released early next year</li>
</ul>
<p>In summary a year of mobile web, including plenty of JavaScript, PhoneGap, responsive web design and testing.</p>
<p>Outside of work I moved into a nice little 1 bed apartment with my girlfriend, cat and 2 hamsters, watched some great films with <a href="http://twitter.com/#!/ribotminimus">@ribotminimus</a>, invested in some of the worlds best kitchen equipment and subsequently did lots of cooking. In an attempt to keep RSI at bay, I did very little blogging and personal projects this year, but lots of exercise. RSI stayed away, so this year I might tempt fate a little&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://mark-kirby.co.uk/2010/2010-in-a-nutshell/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

