<?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>Codeistry blog &#187; Technical</title>
	<atom:link href="http://www.codeistry.com/blog/category/technical/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.codeistry.com/blog</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Fri, 14 Aug 2009 08:10:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Choosing syntax highlighting colours for the draw spaces Gedit plugin</title>
		<link>http://www.codeistry.com/blog/2009/05/choosing-syntax-highlighting-colours-for-the-draw-spaces-gedit-plugin/</link>
		<comments>http://www.codeistry.com/blog/2009/05/choosing-syntax-highlighting-colours-for-the-draw-spaces-gedit-plugin/#comments</comments>
		<pubDate>Mon, 04 May 2009 18:55:11 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[gedit]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[tools]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=297</guid>
		<description><![CDATA[I&#8217;ve recently upgraded to Ubuntu Jaunty &#8211; and therefore Gedit 2.26.1 &#8211; and I couldn&#8217;t figure out how to change the color of spaces shown by the &#8216;Draw Spaces&#8217; plugin. This used to be set in the plugin configuration, but you now do it in the syntax highlighting theme &#8211; but how? What do you [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.codeistry.com/blog/wp-content/uploads/2009/05/gedit-draw-spaces-colours.png"><img class="alignleft size-full wp-image-298" src="http://www.codeistry.com/blog/wp-content/uploads/2009/05/gedit-draw-spaces-colours.png" alt="" width="612" height="309" /></a>I&#8217;ve recently upgraded to Ubuntu Jaunty &#8211; and therefore <a href="http://projects.gnome.org/gedit/">Gedit</a> 2.26.1 &#8211; and I couldn&#8217;t figure out how to change the color of spaces shown by the &#8216;Draw Spaces&#8217; plugin. This used to be set in the plugin configuration, but you now do it in the syntax highlighting theme &#8211; but how? What do you need to add?</p>
<p>The closest that I got googling was this: <a href="https://bugs.launchpad.net/ubuntu/+source/gedit-plugins/+bug/348500">https://bugs.launchpad.net/ubuntu/+source/gedit-plugins/+bug/348500</a> &#8211; which almost tells you but misses out the crucial bit of info.</p>
<p>So, I asked the fine folks in the <kbd>#gedit</kbd> room on <kbd>irc.gnome.org</kbd> and they enlightened me; you need to add this to your syntax theme file:</p>
<pre>&lt;style name="draw-spaces" foreground="tinted_grey"/&gt;</pre>
<p>Where tinted_gray is one of your theme&#8217;s colours. I would put it at the top somewhere, with the rest of the global stuff. You can look in the cobalt.xml file in /usr/share/gtksourceview-2.0/styles for an example of a theme which does this. I thought I&#8217;d put this here so anyone else who get&#8217;s stuck trying to change this has a better chance of Googling an answer.</p>
<p><a href="http://www.codeistry.com/assets/files/twilight.xml">Download a modified version of the Gedit Twilight Theme, with this tweak added</a>. To install, put the file into your <kbd>~/.gnome2/gedit/styles/</kbd> folder and restart Gedit. Then just select the Twilight theme in Preferences.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/05/choosing-syntax-highlighting-colours-for-the-draw-spaces-gedit-plugin/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>MySQL Workbench 5.1.10 beta</title>
		<link>http://www.codeistry.com/blog/2009/04/mysql-workbench-5110-beta/</link>
		<comments>http://www.codeistry.com/blog/2009/04/mysql-workbench-5110-beta/#comments</comments>
		<pubDate>Fri, 10 Apr 2009 19:23:59 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[offtopic]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=289</guid>
		<description><![CDATA[The new MySQL Workbench is now in beta and is looking very good: You can import create scripts (mysqldumps), build diagrams yourself, with full drag and drop etc, and export create scripts. You can also annotate with text and images and export the diagrams as SVG, PDF, PNG etc&#8230; Here&#8217;s the PDF for the MODx [...]]]></description>
			<content:encoded><![CDATA[<p>The new MySQL Workbench is now in beta and is looking very good:</p>
<p><a href="http://www.codeistry.com/blog/wp-content/uploads/2009/04/modx-in-mysql-workbench.png"><img class="alignleft size-medium wp-image-290" title="MySQL Workbench 5.1.10 showing a MODx 0.9.6.3 database" src="http://www.codeistry.com/blog/wp-content/uploads/2009/04/modx-in-mysql-workbench-300x221.png" alt="MySQL Workbench 5.1.10 showing a MODx 0.9.6.3 database" width="300" height="221" /></a>You can import create scripts (mysqldumps), build diagrams yourself, with full drag and drop etc, and export create scripts. You can also annotate with text and images and export the diagrams as SVG, PDF, PNG etc&#8230; Here&#8217;s the PDF<a href="http://www.codeistry.com/assets/files/MODx-in-MySQL-Workbench.pdf"> for the MODx 0.9.6.3 diagram shown</a>, along with the <a href="http://www.codeistry.com/assets/files/MODx.mwb">MWB</a> (workbench) file. That diagram is just an imported mysqldump of a MODx DB &#8211; all I did was click the auto-arrange button.</p>
<p>It&#8217;s available for Linux (32 &amp; 64 bit), Mac and Windows. I&#8217;ve been playing with the 64bit version in Ubuntu and it seems to work great! More info on <a href="http://dev.mysql.com/workbench/">their blog</a>, or get it here: <a href="http://dev.mysql.com/downloads/workbench/5.1.html">http://dev.mysql.com/downloads/workbench/5.1.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/04/mysql-workbench-5110-beta/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>gcalc: a command line version of Google Calculator</title>
		<link>http://www.codeistry.com/blog/2009/04/gcalc-command-line-version-of-google-calculator/</link>
		<comments>http://www.codeistry.com/blog/2009/04/gcalc-command-line-version-of-google-calculator/#comments</comments>
		<pubDate>Fri, 10 Apr 2009 15:17:26 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[fish]]></category>
		<category><![CDATA[gcalc]]></category>
		<category><![CDATA[offtopic]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=272</guid>
		<description><![CDATA[Here’s a command line version of Google Calculator: Download gcalc here: http://www.codeistry.com/assets/files/gcalc.zip It’s a little python script that talks to Google, using it&#8217;s calculator syntax. You&#8217;ll get the same answers if you type the queries into google To use the script, just download the zip file, extract the file inside and put it somewhere on [...]]]></description>
			<content:encoded><![CDATA[<p>Here’s a <a href="http://www.codeistry.com/assets/files/gcalc.zip">command line version of Google Calculator</a>:<a href="http://www.codeistry.com/assets/files/gcalc.zip"><img class="alignnone size-full wp-image-280" title="gcalc command line tool in use" src="http://www.codeistry.com/blog/wp-content/uploads/2009/04/screenshot34.png" alt="gcalc command line tool in use" width="574" height="359" /></a></p>
<p><a href="http://www.codeistry.com/assets/files/gcalc.zip">Download gcalc here: http://www.codeistry.com/assets/files/gcalc.zip</a></p>
<p><img class="alignleft size-full wp-image-285" title="Using Google Calculator in firefox's search box." src="http://www.codeistry.com/blog/wp-content/uploads/2009/04/screenshot36.png" alt="Using Google Calculator in firefox's search box." width="217" height="138" />It’s a little python script that talks to Google, using it&#8217;s calculator syntax. You&#8217;ll get the same answers if you type the queries into google</p>
<p>To use the script, just download the zip file, extract the file inside and put it somewhere on your path; I&#8217;ve started putting these kind of things in <kbd>~/bin</kbd>. I originally found the script here (http://vrai.net/page.php?block=scripts) but it didn’t work too well, so I fixed it up. I&#8217;ve tested it on Linux, but it should work anywhere Python is installed.</p>
<p>If you’re using that script on Linux, then <kbd>chmod +x gcalc</kbd> it to allow it to be executed. If you&#8217;re using Windows, you might have to add &#8216;.py&#8217; to the end of the filename. Then the syntax is very simple:</p>
<p><kbd>gcalc “1 hour 5 minutes in seconds”</kbd><br />
1 hour 5 minutes = 3900 seconds</p>
<p><kbd>gcalc “100 + 2 * 5″</kbd><br />
100 + (2 * 5) = 110</p>
<p><kbd>gcalc “41000 yen in british pounds”</kbd><br />
41,000 Japanese yen = 277.129372 British pounds</p>
<p>Here are <a href="http://www.google.co.uk/help/calculator.html">complete instructions on the syntax that Google Calculator supports</a>.</p>
<p>Also, in the screenshot above I&#8217;m using Fish, the Friendly Interactive SHell because it does nice syntax highlighting, amongst many other cool things. <a title="Friendly Interactive Shell" href="http://www.ibm.com/developerworks/aix/library/au-spunix_fish/?ca=dgr-jw06GoFish&amp;S_TACT=105AGX59&amp;S_CMP=GRsitejw06">Fish is here</a>, if you want it.</p>
<p>Have fun!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/04/gcalc-command-line-version-of-google-calculator/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>9 Steps to Improve your small business website</title>
		<link>http://www.codeistry.com/blog/2009/03/improve-your-small-business-website/</link>
		<comments>http://www.codeistry.com/blog/2009/03/improve-your-small-business-website/#comments</comments>
		<pubDate>Thu, 26 Mar 2009 03:48:45 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Non Technical]]></category>
		<category><![CDATA[Technical]]></category>
		<category><![CDATA[business]]></category>
		<category><![CDATA[design]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=256</guid>
		<description><![CDATA[As a web designer &#38; developer, I see a lot of websites, many of them belonging to small businesses. I&#8217;m also an independent, running my own business &#8211; my website is my shop window, so this subject is close to my wallet heart. There are some common things missing in a lot of the websites [...]]]></description>
			<content:encoded><![CDATA[<p>As a web designer &amp; developer, I see a lot of websites, many of them belonging to small businesses. I&#8217;m also an independent, running my own business &#8211; my website is my shop window, so this subject is close to my <span style="text-decoration: line-through;">wallet</span> heart. There are some common things missing in a lot of the websites that I look at, things that would really improve the website and make it work harder for its owner. Fortunately, most of the missing bits are fairly easy to add.</p>
<p>This list is intended to make you think about your own website and give you practical, actionable steps that you can take right now to improve things. None of these things are difficult and most of them can easily be done in an hour or two. Print this off, mark the ones that you think you need to work on, and tick off one a week.</p>
<p>See the <a href="http://www.codeistry.com/help/improve-your-small-business-website">9 Steps to Improve your small business website article</a> for the steps!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/03/improve-your-small-business-website/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Pasting from Microsoft Word into WordPress or MODx</title>
		<link>http://www.codeistry.com/blog/2009/02/pasting-from-microsoft-word-into-wordpress-or-modx/</link>
		<comments>http://www.codeistry.com/blog/2009/02/pasting-from-microsoft-word-into-wordpress-or-modx/#comments</comments>
		<pubDate>Mon, 16 Feb 2009 18:31:16 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[content]]></category>
		<category><![CDATA[formatting]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=241</guid>
		<description><![CDATA[I&#8217;ve put a new article up in the Codeistry Help section which covers troubleshooting and fixing issues you get copying &#38; pasting code into WordPress, MODx or other web based systems from Microsoft Word. Just in case anyone else gets caught out by this, here&#8217;s the deal: When you copy &#38; paste from Microsoft Word, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve put a new article up in the Codeistry Help section which covers troubleshooting and <a href="http://www.codeistry.com/help/pasting-from-microsoft-word-into-wordpress-or-modx">fixing issues you get copying &amp; pasting code into WordPress, MODx or other web based systems from Microsoft Word</a>. Just in case anyone else gets caught out by this, here&#8217;s the deal:</p>
<p>When you copy &amp; paste from Microsoft Word, into web-based systems like WordPress or MODx, MS Word tries to bring it&#8217;s internal formatting along for the ride. All text in MS Word is styled in some way &#8211; fonts, font sizes, alignment, etc&#8230; so when you copy &amp; paste it into your CMS, blog or whatever, this formatting comes along too, like an invisible hitch-hiker&#8230; <a href="http://www.codeistry.com/help/pasting-from-microsoft-word-into-wordpress-or-modx">See the article for the rest</a>!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/02/pasting-from-microsoft-word-into-wordpress-or-modx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MODx Snippet: New version of Wayfinder</title>
		<link>http://www.codeistry.com/blog/2009/01/modx-snippet-new-version-of-wayfinder/</link>
		<comments>http://www.codeistry.com/blog/2009/01/modx-snippet-new-version-of-wayfinder/#comments</comments>
		<pubDate>Wed, 07 Jan 2009 00:21:51 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[modx]]></category>
		<category><![CDATA[snippet]]></category>
		<category><![CDATA[wayfinder]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=215</guid>
		<description><![CDATA[Good news everyone! During my development travails, I&#8217;ve created an updated version of Wayfinder that fixes two issues and adds two handy new features! Fixes I&#8217;ve incorporated this fix which makes the hereClass work properly with weblinks in the menu and I&#8217;ve fixed the SQL query to work around the MySQL 5.0.51 sorting bug. New [...]]]></description>
			<content:encoded><![CDATA[<p>Good news everyone! During my development travails, I&#8217;ve created an updated version of Wayfinder that <strong>fixes two issues</strong> and <strong>adds two handy new features</strong>!</p>
<h3>Fixes</h3>
<p>I&#8217;ve incorporated <a href="http://modxcms.com/forums/index.php/topic,28461.0.html">this fix</a> which makes the hereClass work properly with weblinks in the menu and I&#8217;ve fixed the SQL query to work around the MySQL 5.0.51 sorting bug.</p>
<h3>New Features</h3>
<h4>lastRowTpl</h4>
<p>I&#8217;ve also added a new parameter called <strong>lastRowTpl</strong> which allows you specify a chunk to be used for the last menu item output. It works the same way as all the other wayfinder tpl&#8217;s and defaults to using rowTpl is it isn&#8217;t specified.</p>
<p>It&#8217;s very useful for little menu&#8217;s that currently look like this if you do them with Wayfinder:</p>
<pre>item1 | item2 | item3 | lastitem |</pre>
<p>and should look like this:</p>
<pre>item1 | item2 | item3 | lastitem</pre>
<h4>Odd &amp; Even classes</h4>
<p>Finally, I&#8217;ve added support for even &amp; odd classes on rows. These work like all the other wayfinder classes &#8211; you specify a class name in the parameter and this will be added to the wf.classes placeholder. These ones are only output on the appropriate rows, though &#8211; and you don&#8217;t have to specify both if you don&#8217;t want to &#8211; it&#8217;ll still work with just one.</p>
<p>These are really useful for menu&#8217;s which are supposed to be stripey, with every other item a different colour.</p>
<p>To implement this, I&#8217;ve modified both Wayfinder files. You can download the new versions from <a href="http://www.codeistry.com/assets/files/wayfinder-201.zip">here (.zip)</a> or <a href="http://www.codeistry.com/assets/files/wayfinder-201.tar.gz">here (.tar.gz)</a>.</p>
<p>I&#8217;m using these on live sites, because I&#8217;m a crazy fool, but if we can get some more testing from everyone, maybe this can be added to the repository as a new version and maybe then into the main MODx distribution, so that everyone can share the love.</p>
<p>What do you think &#8211; <a href="http://modxcms.com/forums/index.php/topic,31895.0.html">let me know in the MODx forum thread</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/01/modx-snippet-new-version-of-wayfinder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New version of MODx CMS out &#8211; 0.9.6.3</title>
		<link>http://www.codeistry.com/blog/2009/01/new-version-of-modx-cms-out-0963/</link>
		<comments>http://www.codeistry.com/blog/2009/01/new-version-of-modx-cms-out-0963/#comments</comments>
		<pubDate>Sun, 04 Jan 2009 01:28:31 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[modx]]></category>
		<category><![CDATA[support]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=90</guid>
		<description><![CDATA[Another pretty sizeable release, despite the small version increment. There are over 100 changes but my personal highlights from the changelog are: Updated AjaxSearch to version 1.8.1 Update eForm to version 1.4.4.5 Update Jot to version 1.1.4 Duplicate TV associations when duplicating a template Allow &#8216;.&#8217;,'-&#8217;,&#8217; &#8216; and &#8216;_&#8217; in TV names Amend the top [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-103" title="MODx Logo" src="http://www.codeistry.com/blog/wp-content/uploads/2009/01/modx-logo-evolution-box-only-75pct.png" alt="" width="114" height="86" />Another pretty sizeable release, despite the small version increment. There are over 100 changes but my personal highlights from the <a href="http://svn.modxcms.com/svn/tattoo/tattoo/releases/0.9.6.3/install/changelog.txt">changelog</a> are:</p>
<ul>
<li>Updated AjaxSearch to version 1.8.1</li>
<li>Update eForm to version 1.4.4.5</li>
<li>Update Jot to version 1.1.4</li>
<li>Duplicate TV associations when duplicating a template</li>
<li>Allow &#8216;.&#8217;,'-&#8217;,&#8217; &#8216; and &#8216;_&#8217; in TV names</li>
<li>Amend the top username link to explicitly state a &#8216;change password&#8217; link instead of just linking the username</li>
<li>Added database version to MySQL DBAPI class and to the System Information report</li>
<li>File manager can now handle files with illegal url characters (added urlencode escaping).</li>
</ul>
<p>The <a href="http://modxcms.com/downloads.html">latest version of MODx can be downloaded here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2009/01/new-version-of-modx-cms-out-0963/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flexible working</title>
		<link>http://www.codeistry.com/blog/2008/12/flexible-working/</link>
		<comments>http://www.codeistry.com/blog/2008/12/flexible-working/#comments</comments>
		<pubDate>Sat, 20 Dec 2008 08:35:04 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Non Technical]]></category>
		<category><![CDATA[Technical]]></category>
		<category><![CDATA[business]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=149</guid>
		<description><![CDATA[I&#8217;ve been working from San Francisco, CA this week, as opposed to my normal Birmingham, UK. My wife was attending the ASCB conference here, so we decided to make a holiday of it and come together. Unfortunately, there hasn&#8217;t been as much holiday as we&#8217;d hoped &#8211; as I&#8217;ve suddenly got more work than expected [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-153" title="Looking down Jones Street, San Francisco, towards Alcatraz island" src="http://www.codeistry.com/blog/wp-content/uploads/2009/01/img_7899.jpg" alt="Looking down Jones Street, San Francisco, towards Alcatraz island" width="225" height="300" />I&#8217;ve been working from San Francisco, CA this week, as opposed to my normal Birmingham, UK. My wife was attending the <abbr title="American Society of Cell Biology">ASCB</abbr> conference here, so we decided to make a holiday of it and come together.</p>
<p>Unfortunately, there hasn&#8217;t been as much holiday as we&#8217;d hoped &#8211; as I&#8217;ve suddenly got more work than expected &#8211; but for me, it&#8217;s proved to be a very useful and successful experiment in flexible working.</p>
<p>While I&#8217;ve been sitting in our apartment on <a href="http://www.745sutter.com/sf/Studio.html" target="_blank">Sutter Street</a>, I&#8217;ve been continuing some web development work for clients in Memphis, TN &amp; done some consulting for a client in London, followed up with a transatlantic training session via Skype.</p>
<p>My wife had a job interview in beautiful and (unusually) snowy Vancouver after the conference, so we spent a day there too. I ended up doing a couple of hours work there, including a Skype call to Memphis, all on my little laptop &#8211; which I bought last time I was in Vancouver.</p>
<p>Back in San Francisco now for a few days of proper holiday and then back to the UK for Christmas Eve &#8211; it&#8217;s been a pretty busy couple of weeks!</p>
<h3>Tools for flexible working</h3>
<p>There were a load of bits of software that helped to make seamlessly working on the road possible, even easy. My laptop is a HP NC6400 that&#8217;s been upgraded to 4Gb of Ram and runs <a href="http://www.ubuntu.com/">the excellent Ubuntu</a> Linux (Intrepid 8.10). This setup is easily capable of running a full LAMP stack, so I can develop websites on the go. I generally use <a href="http://projects.gnome.org/gedit/">gedit</a> for code editing, setup basically like textmate as explained <a href="http://grigio.org/pimp_my_gedit_was_textmate_linux">here</a>, minus the ruby specific bits.</p>
<p><img class="alignleft size-full wp-image-200" title="Screenshot of SpiderOak window, showing device list." src="http://www.codeistry.com/blog/wp-content/uploads/2009/01/screenshot101.png" alt="Screenshot of SpiderOak window, showing device list." width="174" height="285" />I keep a copy of everything &#8211; the contents of my /home folders from my desktop and laptop &#8211; in the cloud using <a href="http://www.spideroak.com/">SpiderOak</a>. This means that I have rolling versioned backups of everything, automatically kept, all the time &#8211; this is very handy on its own. It also means that I can download anything from any of my computers, wherever I am, given internet access. This is very useful when you&#8217;re away from home, as you know that you can&#8217;t really forget anything &#8211; if it&#8217;s available on your desktop PC at home, then you can access it via SpiderOak.</p>
<p>As a last resort, Ubuntu ships with remote desktop support built in, so I can also just connect to my desktop PC over the internet and use it like I was at home, albeit rather slowly.</p>
<p>I also use <a href="http://www.basecamphq.com/">Basecamp</a> for project management which means that my clients and I can manage projects together and keep in touch, wherever I happen to be.</p>
<p>Those are the bits of software that really shone on this trip &#8211; but all the other little ones that I use everyday, most of which are open source, were also just as useful as they always are: <a href="http://mail.google.com/">gmail</a>, <a href="http://www.pidgin.im/">pidgin</a>/<a href="http://live.gnome.org/Empathy">empathy</a>, <a href="http://getdropbox.com/">dropbox</a>, <a href="http://firefox.com/">firefox</a> + <a href="http://getfirebug.com/">firebug</a>, <a href="http://projects.gnome.org/tomboy/">tomboy</a>, <a href="http://gttr.sourceforge.net/">GnoTime</a>, <a href="http://bazaar-vcs.org/">bazaar</a>, etc&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2008/12/flexible-working/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MODx Snippet: ChunkIf</title>
		<link>http://www.codeistry.com/blog/2008/11/modx-snippet-chunkif/</link>
		<comments>http://www.codeistry.com/blog/2008/11/modx-snippet-chunkif/#comments</comments>
		<pubDate>Fri, 28 Nov 2008 14:16:59 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[modx]]></category>
		<category><![CDATA[snippet]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=65</guid>
		<description><![CDATA[Ages ago, I wrote a MODx snippet called ChunkIf and I thought it was about time that I shared it with the MODx community. ChunkIf allows you to choose which of two chunks gets output, based on a template variable being set or not; its not big or clever but I find it useful and [...]]]></description>
			<content:encoded><![CDATA[<p>Ages ago, I wrote a MODx snippet called ChunkIf and I thought it was about time that I shared it with the MODx community. ChunkIf allows you to choose which of two chunks gets output, based on a template variable being set or not; its not big or clever but I find it useful and hopefully you might do, too.</p>
<p>The long form of the snippet call looks like this:</p>
<pre>[[ChunkIf? &amp;tv=`tvname` &amp;trueChunk=`chunkname` &amp;falseChunk=`chunkname`  &amp;debug=`1|0` ]]</pre>
<p>The parameters to the snippet call work like this:</p>
<dl>
<dt>&amp;tv</dt>
<dd>This is the name of the template variable you want to test. The value of this variable will be checked and if it&#8217;s not empty or blank, &amp;trueChunk will be output &#8211; otherwise &amp;falseChunk will be.</dd>
<dt>&amp;trueChunk</dt>
<dd>The name of the chunk who&#8217;s content you want output, in the event that your template variable (&amp;tv) has a value.</dd>
<dt>&amp;falseChunk</dt>
<dd>The name of the chunk who&#8217;s content you want output, if your template variable (&amp;tv) is empty. If you omit this parameter, an empty string will be output if &amp;tv is empty.</dd>
<dt>&amp;debug</dt>
<dd>Set this to 1 to emit debugging comments into the HTML output; set it to 0 or leave it out to switch off.</dd>
</dl>
<p>There is a short version too:</p>
<pre>[[ChunkIf? &amp;tv=`tvname` ]]</pre>
<p>The shorthand form attempts to output the contents of a chunk with the same name as &amp;tv, if &amp;tv is set, or an empty string. If there&#8217;s no chunk with the same name, it also returns an empty string.</p>
<p>This shorthand version is very handy for switching chunks on and off using a single variable. As chunks can contain other chunks and snippet calls, you can use this to switch sidebars, footers and other complex bits of layout on and off on a per page basis, with a simple checkbox template variable.</p>
<pre class="brush: php; ">

&lt;?php
	/*
		Version: 0.2
		Date: 21/07/2008
		Description:
			&lt;strong&gt;0.2&lt;/strong&gt; Outputs the contents of the chunk passed in
			$trueChunk if the template variable passed in $tv is set (i.e. has a value).
			Otherwise outputs the contents of the $falseChunk chunk. Expects $tv to be the
			name of the Template Variable to test, and $trueChunk &amp; $falseChunk to be names
			of chunks.

		eg:

		[[ChunkIf? &amp;tv=`tvname` &amp;trueChunk=`chunkname` &amp;falseChunk=`chunkname` ]]
			- Long version outputs $trueChunk if $tv has a value, otherwise
			outputs $falseChunk.
		[[ChunkIf? &amp;tv=`tvname` &amp;trueChunk=`chunkname` ]]
			- This short version outputs an empty string if $tv has no value.
		[[ChunkIf? &amp;tv=`tvname` ]]
			- This very short version attempts to output the contents of a chunk
			 with the same name as $tv
		[[ChunkIf? &amp;tv=`tvname` &amp;debug=`1` ]]
			- Switches on debugging output - output&#039;s HTML comments for debugging.

	*/

	// get tv name
	$tv = isset( $tv ) ? $tv : &#039;&#039;;

	// get current page ID
	$id = isset( $id )? $id: $modx -&gt; documentObject[&#039;id&#039;];

	// Get the value of $tv
	$tvarray = $modx -&gt; getTemplateVarOutput( $tv, $id );
	$value = &#039;&#039;.trim($tvarray[$tv]);

	if ($debug) {
		$dtmp = &#039;&lt;!--&#039;;
		$dtmp .= &#039;tv: &#039;.$tv.&#039;, &#039;;
		$dtmp .=  &#039;id: &#039;.$id.&#039;, &#039;;
		$dtmp .=  &#039;value: &#039;.$value;
		$dtmp .=  &#039;--&gt;&#039;;

		echo $dtmp;
	}

	// Decide which chunk to return.
	if ($value == &#039;&#039;) {
		// get chunk to return if $tv has no value
		$falseChunk = isset( $falseChunk )? $modx -&gt; getChunk( $falseChunk ): &#039;&#039;;
		return $falseChunk;
	} else {
		// get chunk to return if $tv has a value
		if (isset( $trueChunk ))
		{
			$trueChunk = $modx -&gt; getChunk( $trueChunk );
		} else {
			// Attempt to get the chunk with the same name as $tv
			$trueChunk = $modx -&gt; getChunk( $tv );
		}
		return $trueChunk;
	}
?&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2008/11/modx-snippet-chunkif/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>New version of MODx CMS out &#8211; 0.9.6.2</title>
		<link>http://www.codeistry.com/blog/2008/09/new-version-of-modx-out-0962/</link>
		<comments>http://www.codeistry.com/blog/2008/09/new-version-of-modx-out-0962/#comments</comments>
		<pubDate>Wed, 17 Sep 2008 00:44:37 +0000</pubDate>
		<dc:creator>Duncan Lock</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[modx]]></category>
		<category><![CDATA[support]]></category>

		<guid isPermaLink="false">http://www.codeistry.com/blog/?p=7</guid>
		<description><![CDATA[While the numbering scheme would imply a simple patch, it is in fact a substantial upgrade, especially in the areas of security and Manager functionality.]]></description>
			<content:encoded><![CDATA[<p>A new version of MODx has just been released &#8211; 0.9.6.2, with a whole bunch of fixes and updates. There have been loads of fixes and updates checked-in by the MODx team &amp; the community since 0.9.6.1 and lots of code clean-up and multi-language fixes done.</p>
<p>See <a rel="external" href="http://modxcms.com/forums/index.php/topic,28875.msg175378.html#msg175378">here for MODx forum announcement</a> and here for the <a rel="external" href="http://svn.modxcms.com/svn/tattoo/tattoo/releases/0.9.6.2/install/changelog.txt">complete (long &amp; technical) changelog</a>.</p>
<p>I&#8217;ll be upgrading the Codeistry site over the next few days and and then rolling the update out to all client sites as soon as possible after that.</p>
<p>My highlights amongst the many changes are:</p>
<h4>Allow weblinks to have summary (introtext) fields</h4>
<p>Weblink documents can now have an introtext summary, like normal documents, which is quite handy.</p>
<h4>Set the published status of duplicated documents to unpublished</h4>
<p>When you duplicate a document, it will now be set to un-published. Previously it would copy the published status of the document that you were duplicating &#8211; which was almost never what you really wanted.</p>
<h4>Updated @INHERIT TV command to see through un-published pages.</h4>
<p>Template variables which inherit their values from their parent documents, will now do so even if their parent document isn&#8217;t published; this propagates down through the site structure.</p>
<h4>Added a manager role for emptying the trash/permanently purging docs</h4>
<p>There&#8217;s now a manager role for permanently deleting documents which is handy in setups with lots of users.</p>
<h4>Added plugin to show image previews in the manager for Image TVs</h4>
<p><img class="alignleft" title="Screenshot showing Template variable Image plugin working." src="/assets/images/blog/new-version-of-modx-out-0.9.6.2/image_tv_plugin_resized.png" alt="Screenshot showing Template variable Image plugin working." width="238" height="210" />Really nice feature which shows you a thumbnail preview of the image being used by a template variable while you&#8217;re editing the page.</p>
<h4>TinyMCE 3.1.0.1a and MCPUCK file browser improvements</h4>
<p>This is great &#8211; the document content editor component has been updated to the latest version &#8211; which saves me from doing it on every install. This newer version of the editor is a big improvement on the previous one shipped with MODx 0.9.6.1</p>
<h4>Updated &#8216;built-in&#8217; snippets:</h4>
<ul>
<li>Updated Jot snippet to version 1.1.3</li>
<li>Updated Breadcrumbs snippet to 1.0.1</li>
<li>Update AjaxSearch to 1.7.1 and Search Highlighting plugin to 1.2.0.2</li>
<li>Update Ditto/Reflect to version 2.1</li>
<li>Migrated Mootools to 1.11</li>
</ul>
<h4>Patches to Ditto 2.1 to fix sorting and change default docs displayed number from 3 to &#8220;all&#8221;</h4>
<p>Ditto will now display all documents it finds by default, instead on only the first 3, and sort order fixes for MySQL 5.0.31a</p>
<h4>Added the ability to easily add custom help pages to the manager.</h4>
<p><img class="alignleft" title="Screenshot of the help MODx manager help page, showing a new test tab." src="/assets/images/blog/new-version-of-modx-out-0.9.6.2/help_page_tabs.png" alt="Screenshot of the help MODx manager help page, showing a new test tab." width="221" height="158" />This really <em>is</em> simple &#8211; just create the HTML files in the /manager/help folder and they appear at tabs on the Help page. Neat &#8211; I&#8217;ll be taking advantage of this in due course.</p>
<h4>Fix to alphabetical sorting in MCPUCK browser</h4>
<p>Fix for sorting images alphabetically in the image browser. This now seems to work properly, the image browser sorts images alphabetically, making it much easier to use, especially if you&#8217;ve got lots of images in a folder.</p>
<h4>Added XML doctype and header to MCPUK for file uploads</h4>
<p>This should fix a very annoying error when uploading files via the resource browser, especially in Internet Explorer.</p>
<h4>Added RSS Feeds of the Security Announcements and Important News to the Manager Login Welcome Page.</h4>
<p><img class="alignleft" title="Screenshot on the new MODx Manager Welcome page, showing new RSS feed tabs." src="/assets/images/blog/new-version-of-modx-out-0.9.6.2/welcome_page_feeds.png" alt="Screenshot on the new MODx Manager Welcome page, showing new RSS feed tabs." width="317" height="184" />This is quite useful &#8211; it helps keep site administrators up to date with the latest MODx releases and security updates.</p>
<h4>Fix &#8216;Allowed Days&#8217; checkboxes for Manager users</h4>
<p>These were previously the wrong way round &#8211; unchecked when they should have been checked, as I discovered the other day during a live demo.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.codeistry.com/blog/2008/09/new-version-of-modx-out-0962/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
