<?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>Christopher Hill</title>
	<atom:link href="http://www.chrisjhill.co.uk/feed" rel="self" type="application/rss+xml" />
	<link>http://www.chrisjhill.co.uk</link>
	<description>My personal site</description>
	<lastBuildDate>Wed, 11 Mar 2020 15:07:09 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.5.14</generator>
	<item>
		<title>The Advocate</title>
		<link>http://www.chrisjhill.co.uk/article/the-advocate</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Thu, 11 Jan 2018 18:03:55 +0000</pubDate>
				<category><![CDATA[Personal]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1310</guid>

					<description><![CDATA[I am an INFJ, apparently making me the rarest type in Myers–Briggs Type Indicator: only around 1% of the population. INFJ: Introversion, Intuition, Feeling, and Judging. I walk alongside other INFJ's such as Martin Luther King, Nelson Mandela, and Mother Teresa.]]></description>
										<content:encoded><![CDATA[<p>I don&#8217;t necessarily believe in “mystic” or “fortunes”, however I recently took the 16 personalities test, based on the <a href="https://en.wikipedia.org/wiki/Myers%E2%80%93Briggs_Type_Indicator">Myers–Briggs Type Indicator</a> and was pleasantly surprised with how accurate it seems. It says that I am an INFJ, apparently making me the rarest type: only around 1% of the population. INFJ: Introversion, Intuition, Feeling, and Judging.</p>
<p>I walk alongside other INFJ&#8217;s such as Martin Luther King, Nelson Mandela, and Mother Teresa.</p>
<h2>General overview of an INFJ</h2>
<blockquote><p>As Diplomats, they have an inborn sense of idealism and morality, but what sets them apart is the accompanying Judging trait – INFJs are not idle dreamers, but people capable of taking concrete steps to realize their goals and make a lasting positive impact. Though soft-spoken, they have very strong opinions and will fight tirelessly for an idea they believe in. They are decisive and strong-willed, but will rarely use that energy for personal gain</p></blockquote>
<p>&#8220;If you fail to plan, you are planning to fail&#8221;, as Benjamin Franklin once said. I&#8217;m a massive planner (seriously, you should see my diary…) and believe that you really do need to plan things out thoroughly to meet your goal. You need to work out where the stumbling blocks might be and plan accordingly &#8211; a Web Application isn&#8217;t a simple straight line to your endpoint, it&#8217;s like a country road: winding and swerving all over the place. Planning projects is hard, but it is doable when broken down into small, manageable, bite-sized pieces.</p>
<h2>INFJ as a leader</h2>
<blockquote><p>INFJs are often reluctant in exercising their authority, preferring to see their subordinates as equals, coordinating and supervising people, and working hard to inspire and motivate, not to crack the whip. That’s not to say that people with the INFJ personality type have lax standards – far from it – as INFJs’ sense of equality means that they expect their subordinates to be as competent, motivated and reliable as the INFJs themselves.</p></blockquote>
<p>This is me in a nutshell. I value colleagues, value their opinions, their work patterns, and the work they do &#8211; we&#8217;re all humans after all, everyone is created equal. What I want is to encourage others to perform better, giving advice and mentoring where required. Work them too hard, set unrealistic goals, or ill-treating them will only create the opposite of what you are trying to achieve.</p>
<hr />
<p>Piqued your interest? <a href="https://www.16personalities.com/free-personality-test">Go ahead and give it a try now</a> to see which one of the 16 personalities you are.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Broken Windows</title>
		<link>http://www.chrisjhill.co.uk/article/broken-windows</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Fri, 07 Oct 2016 22:21:21 +0000</pubDate>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Web Design]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1232</guid>

					<description><![CDATA[There is an interesting theory that came around in 1982 by two American social scientists named James Wilson and George Kelling called "Broken Windows". This stated that maintaining law and order quickly in urban areas would result in fewer crimes and de-escalating crimes of severity.]]></description>
										<content:encoded><![CDATA[<p>There is an interesting theory that came around in 1982 by two American social scientists named James Wilson and George Kelling called &#8220;<a href="https://en.wikipedia.org/wiki/Broken_windows_theory">Broken Windows</a>&#8220;. This stated that maintaining law and order quickly in urban areas would result in fewer crimes and de-escalating crimes of severity. Their paper stated:</p>
<blockquote><p>
Consider a building with a few broken windows. If the windows are not repaired, the tendency is for vandals to break a few more windows. Eventually, they may even break into the building, and if it&#8217;s unoccupied, perhaps become squatters or light fires inside.</p>
<p>Or consider a pavement. Some litter accumulates. Soon, more litter accumulates. Eventually, people even start leaving bags of refuse from take-out restaurants there or even break into cars.<br />
<cite><a href="http://www.theatlantic.com/magazine/archive/1982/03/broken-windows/304465/">Broken Windows, the police and neighborhood safety</a></cite>
</p></blockquote>
<p>So how does this tie into Web Development? Like the example above, if there are &#8220;bad things&#8221; in the code then developers will be more likely to further contaminate that file with &#8220;bad&#8221; things&#8221;, because the file already needs a refactor. But that refactor will happen next week/month/year (never, most likely) and everything will be right again in the world. So there&#8217;s no sense in doing that now and blowing the deadline for the whole project which needs to be shipped in 2 weeks.</p>
<p>Sound familiar?</p>
<p>This solution doesn&#8217;t make sense for most programming languages, but it does for CSS due to its weird specificity and cascading nature. You have a new file for each project named <var>shame.css</var> which contains all of the hacks that you have had to add in order to ship on time. This is great because of several reasons:</p>
<ol>
<li>All of your hacks are self contained within a single file, not contaminating the rest of the sane code.</li>
<li>You are admitting there are hacks, but each hack should have its own comment saying why it&#8217;s necessary, what it does, and how it can be fixed.</li>
<li>Have a spare hour? You can easily dive straight in and fix a hack.</li>
<li>You can see who was responsible for the hacks (<var>$ git blame -l shame.css</var>).</li>
</ol>
<p>The forth point is actually not a blame game, but you can possibly spot trends. If one developer is making a lot of hacks with regards to, say, the grid system then they may need to be given a quick chat on how it works and what they were doing wrong &#8211; this will make them more productive in the future.</p>
<p>It&#8217;s also a file where someone who isn&#8217;t that well versed in CSS can place a snippet, knowing that someone will come along and implement it correctly in the codebase in the future.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Service Manuals</title>
		<link>http://www.chrisjhill.co.uk/article/service-manuals</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Mon, 30 Nov 2015 09:12:29 +0000</pubDate>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Web Design]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1184</guid>

					<description><![CDATA[Service Manuals, Playbooks, Style Guides, call them what you want but to any large-ish organisation they are a vital way to maintain consistency among the different departments and outside organisations, to ensure your brand does not get misused and misrepresented.]]></description>
										<content:encoded><![CDATA[<p>Service Manuals, Playbooks, Style Guides, call them what you want but to any large-ish organisation they are a vital way to maintain consistency among the different departments and outside organisations, to ensure your brand does not get misused and misrepresented.</p>
<p>It&#8217;s a sad fact* that many people see no value in service manuals, because many of them have never been in a development environment. Actually, the outlay in a few days work can result in massive payoffs:</p>
<ol>
<li>More refined code</li>
<li>Shared code (markup, behavioural, and styling)</li>
<li>Brand consistency</li>
<li>Maintainability</li>
<li>Happy designers and developers</li>
</ol>
<p>I really cannot emphasise how important everything on that list is, so let&#8217;s take them one-by-one.</p>
<h3>More refined code</h3>
<p>You have already discussed everything in the service manual with the other developers who, hopefully, largely agree that everything in there is sane, useful, and correct. This leads to a greater proportion of the code already having been code reviewed.</p>
<h3>Shared code (markup, behavioural, and styling)</h3>
<p>Need to add a button? It&#8217;s already there. A table? Already there. A carousel? Despite the numerous experiments proving they do not work aside, already there. Which colour do I use for this thing? Already there. How many pixels should this image be here? Already there.</p>
<p>Not only does this allow the developers to focus on their work, it frees up the designers time allowing them to get on with what they like to do best: design. Interrupting a developer also causes massive time wastage, this article entitled &#8220;<a href="http://blog.ninlabs.com/2013/01/programmer-interrupted/">Programmer Interrupted</a>&#8221; gives an excellent overview on why it takes ~15 minutes for a developer to get back &#8220;into the flow&#8221;.</p>
<p>If you&#8217;re an agency then you also have the components that you can reuse project after project, just needing to update the CSS to have a unique brand associated element.</p>
<h3>Brand consistency</h3>
<p>This one is quite obvious: The service manual will define colours, type faces, visuals, and the padding/margin required, all leading to a consistent feeling across the website <em>and</em> their offline stationary, banners, signage, work clothes, etc. This won&#8217;t be used just by internal teams, but external as well &#8211; make sure they know how your brand should be portrayed.</p>
<h3>Maintainability</h3>
<p>Let&#8217;s take for example the carousel. Update the Javascript for it and every single item will then be updated. You don&#8217;t need to update each one individually. Has one of your brand colours been updated from #FFF to #FFE? No problem, just update the SASS variable and it will flow down to everything using it (you are using SASS, right?)</p>
<p>Also, because everything has been determined before a single line of code has been written it means there is far less spaghetti code. Spaghetti code is hard to maintain, makes the barrier to entry point higher for new developers, and causes bugs.</p>
<h3>Happy designers and developers</h3>
<p>A crucial point; making your staff happy matters. It will improve the office morale, make them work harder which will pay dividends in the quality of work they ship, and creates a friendly working atmosphere where they enjoy coming to work &#8211; don&#8217;t make them dread the morning alarm clock. It&#8217;s also the right thing to do.</p>
<h3>Conclusion</h3>
<p>So, a service manual isn&#8217;t a waste of time. It isn&#8217;t just about what colour something should be. It has far more meaning and importance than one first gives it credit. It will save you time and money. Please, use one and make the world a better place. Some excellent service manuals can be found below for your enjoyment:</p>
<ul>
<li><a href="https://www.gov.uk/service-manual">UK Government Service Manual</a></li>
<li><a href="https://www.gov.uk/design-principles">UK Government Design Principles</a></li>
<li><a href="https://playbook.cio.gov/">US Government Playbook</a></li>
<li><a href="http://www.bbc.co.uk/gel">BBC Global Experience Language</a></li>
<li><a href="https://www.mozilla.org/en-US/styleguide/">Mozilla Styleguide</a></li>
</ul>
<p><em>* my own personal experience of ~100 clients and organisations</em></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Cleaning up after yourself</title>
		<link>http://www.chrisjhill.co.uk/article/cleaning-up-after-yourself</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Wed, 04 Mar 2015 09:01:47 +0000</pubDate>
				<category><![CDATA[PHP]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1218</guid>

					<description><![CDATA[Everyone likes a nice clean interface; some of the required scaffolding simply gets in the way of what we want to do. A classic example of this is closing things automatically; there are several ways to do this (using tweaked code examples from the PHP manual):]]></description>
										<content:encoded><![CDATA[<p>Everyone likes a nice clean interface; some of the required scaffolding simply gets in the way of what we want to do. A classic example of this is closing things automatically; there are several ways to do this (using tweaked code examples from the PHP manual):</p>
<h2>Finally</h2>
<p>You can see that, in the code below, we do not call <var>fclose</var> when we throw an exception because the <var>finally</var> will kick in and do it for us automatically.</p>
<pre>
function example($url) {
    try {
        $handle   = fopen($url, "rb");
        $contents = '';

        if (false === $handle) {
            throw Exception('Failed to open stream to URL');
        }

        while (! feof($handle)) {
            $contents .= fread($handle, 8192);
        }

        return $contents;
    } finally {
        fclose($handle);
    }
}
</pre>
<h2>Deferred</h2>
<p>&#8220;finally&#8221; is an <em>OK</em> method, but then one ends up having try-catch blocks all over the place. It&#8217;s much better to have an interface to do it for us. In the programming language Go there is a feature called <a href="https://tour.golang.org/flowcontrol/12"><var>defer</var></a> which prevents things from executing until a function has complete. It would be nice to do this in PHP. Consider the following using a <var>Defer</var> class and a closure:</p>
<pre>
class Defer
{
    private $closure;

    public function __construct($closure) {
        $this-&gt;closure = $closure;
    }

    public function __destruct() {
        call_user_func($this-&gt;closure);
    }
}

function example($url) {
    $handle   = fopen($url, "rb");
    $contents = '';

    // Magic happens here
    // Pass the $handle into the closure so we have access to it
    // When the function ends the variables will be out of scope and the $defer deconstructor
    // .. will be automatically called, closing the connection.
    $defer = new Defer(function () use ($handle) {
        fclose($handle);
    });

    if (false === $handle) {
        throw Exception('Failed to open stream to URL');
    }

    while (! feof($handle)) {
        $contents .= fread($handle, 8192);
    }

    return $contents;
}
</pre>
<p>The benefits of this are that you can pass anything into the <var>Defer</var> class to have it destroyed (or any other kind of functionality, come to that) when it goes out of scope: opening files, curl requests, etc.).</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Magic Mirror</title>
		<link>http://www.chrisjhill.co.uk/article/magic-mirror</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Thu, 30 Oct 2014 08:13:31 +0000</pubDate>
				<category><![CDATA[Personal]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1161</guid>

					<description><![CDATA[This guy could be on to something. There is a definite huge gap in the market for a quick and easy way to see what's going on whilst you get ready, without having to look at your phone and then get distracted on Facebook, Clash of Clans, or an email.]]></description>
										<content:encoded><![CDATA[<p><img src="http://67.media.tumblr.com/62a121f6f7176ca52a2d182564d13f75/tumblr_inline_n4kvkeHSMo1s95p1z.jpg" alt="" style="float:right;margin-right:-30%;padding:10px" /></p>
<p><a href="http://michaelteeuw.nl/tagged/magicmirror">This guy could be on to something</a>.</p>
<p>There is a definite huge gap in the market for a quick and easy way to see what&#8217;s going on whilst you get ready, without having to look at your phone and then get distracted on Facebook, Clash of Clans, or an email.</p>
<p>The question is: is this that useful? And by that, I mean sure, the weather is quite important&#8230; but is it really? I can tell you roughly what the weather will be by the month of the year; December will be cold, take a coat, July will be warm, rock a tee with shorts. The time&#8230; sure, but there&#8217;s your watch and your phone to tell you that instantly. News stories… you&#8217;re there to get ready, not know that Apple have just announced a new MacBook. The one area this interests me is with your calendar; showing you a schedule of what&#8217;s happening is really cool and one where you might have forgotten to do something.</p>
<p>I would imagine this is an in-between phase. The ideal solution would be something you can talk and interact with, without having to &#8220;look&#8221; at it. Kind of like Google Now, how you can say &#8220;OK, Google, what will the weather be like today&#8221; and it responds accordingly. Think Star Trek, or Galaxy Quest, with a computer ready to fetch and dictate information. Making it extensible would be awesome, imagine saying &#8220;Ok, Google, what&#8217;s my day like?&#8221; and it responds with:</p>
<blockquote>
<p>Hi Chris, you have a meeting with Steve this morning in Bath. Traffic is pretty heavy so you&#8217;ll need to leave in 20 minutes to get there on time. Don&#8217;t forget to take an umbrella and coat, it&#8217;s likely to rain and will have a high of 16 degrees. It&#8217;s your mum&#8217;s birthday today, grab some flowers on the way home.</p>
</blockquote>
<p>Like the PC, there&#8217;ll be one of these in every home in 20 years time. Now, where&#8217;s my chequebook, I need to invest in something…</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Getting Sassy</title>
		<link>http://www.chrisjhill.co.uk/article/getting-sassy</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Tue, 08 Jul 2014 11:28:22 +0000</pubDate>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Web Design]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1254</guid>

					<description><![CDATA[My stance on CSS preprocessors in the past has been far from glowing, but I'm slowly coming around. Slowly being the keyword. But I'm there now, I love it. I used to think it was just because of variables, but actually the syntax is nicer than CSS. There, I said it, humble pie. And it's not just because it's leaner, it's actually more maintainable, and I'm going to give you three quick examples why.]]></description>
										<content:encoded><![CDATA[<p>My stance on CSS preprocessors in the past has been far from glowing, but I&#8217;m slowly coming around. Slowly being the keyword. But I&#8217;m there now, I love it. I used to think it was just because of variables, but actually the syntax is nicer than CSS. There, I said it, humble pie. And it&#8217;s not just because it&#8217;s leaner, it&#8217;s actually more maintainable, and I&#8217;m going to give you three quick examples why.</p>
<h2>1. Nesting</h2>
<p>I used to write CSS on one line, and then indent the next if it was a child of the previous element. This worked really well and helps to understand inheritance and the way the markup is structured, and means you can see as much CSS on the screen at once as possible. I&#8217;ll give you an example:</p>
<pre>
&lt;div id="header"&gt;
    &lt;div class="foo"&gt;
        &lt;p&gt;
            &lt;span&gt;Lorem ipsum&lt;/span&gt;
            &lt;a href="#"&gt;Link&lt;/a&gt;
        &lt;/p&gt;
    &lt;/div&gt;
&lt;/div&gt;

#header{...}
    #header .foo{...}
        #header .foo span{...}
        #header .foo a{...}
</pre>
<p>However, if I now come to change the ID to something different I have to do it on every line. And if I have to change every line that means git has to track that. And if git has to track all those lines, then anyone else making a change means there will be conflicts. As such, it&#8217;s no longer a viable option: git should be able to tell you <em>exactly</em> what has changed, without confusion or conflicts for the tiniest change. With SASS this now looks like:</p>
<pre>
#header {
    .foo {
        span {
            ...
        }

        a {
            ...
        }
    }
}
</pre>
<p>Changed a element ID/class? Obvious. Changed a property? Obvious. No longer need to sift through the line comparing what had changed manually.</p>
<p>It&#8217;s also less code to write, notice that I haven&#8217;t had to write <var>#header .foo{&#8230;}</var>, I just need to ensure it&#8217;s nested correctly. Of course this still gets compiled to the exact same CSS as the first example, so the output is the same.</p>
<h2>2. Partials and Imports</h2>
<p>When you have a large CSS code base, as we do at <a href="https://www.ents24.com">Ents24</a>, you really want to separate each component into their own respective file. Need to update the navigation? Head on over to <var>nav.scss</var>. The footer, well, that&#8217;s in <var>footer.scss</var>! I know that you can do this in CSS with <var>@import</var>, but that&#8217;s a new HTTP connection right there. Have 10, 20, or maybe even 50 of them and suddenly you&#8217;re in trouble. Yes, you could minify the files together but that&#8217;s still a bit of a hassle. It&#8217;s far easier to let SASS do it, and when you have multiple projects which all pick-and-chose the components, it&#8217;s a no-brainer.</p>
<p>You can have a master CSS file per project that is essentially a list of <var>@import</var>&#8216;s for each component it requires. Each of those components come from a compiled SASS file, and each of those SASS files can make use of a single base file, variable file, and mixin file to make everything streamlined across your project. For instance, consider this folder structure:</p>
<pre>
`- sass
    |- _base.scss
    |- _variables.scss
    |- _mixins.scss
    |- grid.scss
    |- header.scss
    |- footer.scss
    |- nav.scss
    |- button.scss
    `- table.scss
`- css
    |- grid.scss
    |- header.scss
    |- footer.scss
    |- nav.scss
    |- button.scss
    `- table.scss
`- project
    |- desktop.css
    |- desktop.min.css
    |- mobile.css
    |- mobile.min.css
    |- widget.css
    |- widget.min.css
    |- foobar.css
    `- foobar.min.css
</pre>
<p>The <var>sass</var> folder will contain the files you edit, these are then automatically compiled down into their respective files in the <var>css</var> folder (the SASS files with an underscore will not get compiled!), and when those files are updated they will trigger the <var>project</var> files to be updated, and then those will be automatically minified for you to use in production.</p>
<p>You can hopefully suddenly see the huge benefits. <var>desktop.css</var> and <var>mobile.css</var> might actually make use of each of the CSS files, but the widget project might be a tiny thing that people can add to their own sites, and might only require the <var>grid.css</var> and <var>button.css</var> files. You&#8217;ve now a consistent brand feel across everything you do for free, and with ease of maintenance. Win.</p>
<h2>3. Mixins</h2>
<p>And lastly we come to mixins. These are small snippets of CSS which are frequently used throughout your codebase which are often annoying to write. An example of this is rounded corners. Remembering each vendor prefix is a pain and quite honestly I can&#8217;t count the number of times I&#8217;ve simply used <var>border-radius</var> in isolation and forgotten about old browsers. <strong>Update</strong>: Although a good example, this is probably bad practice now; you shouldn&#8217;t really use vendor prefixes too much, let older browsers degrade nicely.</p>
<p>We can define our mixins in our <var>mixins.scss</var> file, something like:</p>
<pre>
@mixin border-radius($radius) {
  -webkit-border-radius: $radius;
     -moz-border-radius: $radius;
      -ms-border-radius: $radius;
          border-radius: $radius;
}
</pre>
<p>And then make use of them in our SASS files:</p>
<pre lang="css">
#header {
    @include border-radius(10px);

    div {
        @include border-radius(8px);
    }
}
</pre>
<p>This saves us a huge amount of time, makes things easier to maintain, and also gives us a single place to contain horrible things like vendor prefixes, so once you no longer need them you can easily switch them out.</p>
<h2>To sum up</h2>
<p>I could have talked about variables, but you already know about them and how they make things easier. I could have talked about how you can easily make drop shadows just by using <var>darken($color-x-feature, 10%)</var>, but that&#8217;s something for you to learn on your own&#8230; wait, I just did. I&#8217;m trying to say there&#8217;s a lot more to SASS than variables. If you&#8217;re a project manager or team lead and you&#8217;re looking to make your employees happier, more productive, and your codebase more maintainable, then you could do a lot worse than having a quick look at SASS.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Yoda natation</title>
		<link>http://www.chrisjhill.co.uk/article/yoda-natation</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Wed, 04 Dec 2013 08:32:28 +0000</pubDate>
				<category><![CDATA[PHP]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1206</guid>

					<description><![CDATA[Everyone's done it, they've missed the second equals sign in an if-statement and created an assignment instead. Much tutting, shaking of the head, and a little chuckle ensues as you realise your error. There is a thought amongst some that Yoda notation is the way to go, so named because it switches the comparative's to produce errors instead of unexpected behaviour.]]></description>
										<content:encoded><![CDATA[<p>Everyone&#8217;s done it, they&#8217;ve missed the second equals sign in an if-statement and created an assignment instead. Much tutting, shaking of the head, and a little chuckle ensues as you realise your error. There is a thought amongst some that Yoda notation is the way to go, so named because it switches the comparative&#8217;s to produce errors instead of unexpected behaviour. Consider the following:</p>
<pre>
if ($theSkyColour = 'blue') {
    // This will always be called, because the value will be "returned"
    // Equivalent of if ('blue') {
}
</pre>
<p>If you would switch the comparatives around you would end up with:</p>
<pre>
if ('blue' = $theSkyColour) {
    // I will produce an error
    // PHP Parse error:  syntax error, unexpected '=' in file.php
}
</pre>
<p>So you immediately know there is something wrong and you can correct it before it lands in production. But is this the best way to go about it? Possibly, it&#8217;s a matter of opinion; it&#8217;s been around for years and has made its way into some of the largest PHP projects such as WordPress, Symfony, etc.</p>
<h2>Disadvantages</h2>
<ol>
<li>It&#8217;s harder to read: &#8220;Is the sky blue?&#8221; is much easier for us to understand than &#8220;Blue is the sky colour?&#8221;.</li>
<li>Is maintainability more important than a potential bug? I&#8217;m sure there will be people on both sides of the fence, and some in the middle collecting splinters.</li>
<li>Nowadays IDE&#8217;s tend to prevent this kind of thing from happening, you can set them to give warnings on assignments in conditions.</li>
<li>You can use a piece of software like <a href="https://github.com/squizlabs/PHP_CodeSniffer">PHP Code Sniffer</a> in your build tool and reject anything that contains these potential nasties.</li>
<li>And, most importantly, it isn&#8217;t a silver bullet; it will do nothing to prevent the code below from being incorrect or error&#8217;ing:</li>
</ol>
<pre>
if ($foo = $bar) {
    // I am always run and no errors are ever thrown
}
</pre>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Javascript: URI.js</title>
		<link>http://www.chrisjhill.co.uk/article/javascript-uri-js</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Tue, 24 Jul 2012 08:54:59 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1067</guid>

					<description><![CDATA[URI.js is a javascript library for working with URLs. It offers a &#8220;jQuery-style&#8221; API (Fluent Interface, Method Chaining) to read and write all regular components and a number of convenience methods like .directory() and .authority().]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>URI.js is a javascript library for working with URLs. It offers a &#8220;jQuery-style&#8221; API (Fluent Interface, Method Chaining) to read and write all regular components and a number of convenience methods like .directory() and .authority().</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>HTML5 mockup site: Moqups</title>
		<link>http://www.chrisjhill.co.uk/article/html5-mockup-site-moqups</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Thu, 12 Jul 2012 08:02:36 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1064</guid>

					<description><![CDATA[There are many alternatives (Balsamiq and Go Mockingbird, to name a few) and haven&#8217;t delved too deeply, but looks like a solid (free, for now) alternative.]]></description>
										<content:encoded><![CDATA[<p>There are many alternatives (Balsamiq and Go Mockingbird, to name a few) and haven&#8217;t delved too deeply, but looks like a solid (free, for now) alternative.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>An introduction to PDO: The basics and benefits</title>
		<link>http://www.chrisjhill.co.uk/article/an-introduction-to-pdo-the-basics-and-benefits</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Wed, 11 Jul 2012 12:54:14 +0000</pubDate>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[SQL]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1051</guid>

					<description><![CDATA[MySQL is/was deeply integrated within PHP. No doubt you have seen and used the <tt>mysql_*()</tt> functions at some stage, but there is an alternative that makes your database interactions much more reliable. It's called PDO (PHP Data Object) and here's a quick guide that should get you up to speed in no time at all.]]></description>
										<content:encoded><![CDATA[<p>MySQL is/was deeply integrated within PHP. No doubt you have seen and used the <tt>mysql_*()</tt> functions at some stage, but there is an alternative that makes your database interactions much more reliable. It&#8217;s called PDO (PHP Data Object) and here&#8217;s a quick guide that should get you up to speed in no time at all.</p>
<h2>Why use PDO?</h2>
<p>The number one reason is security. With plain MySQL functions you need to sanitise the input manually using type casting or <tt>mysql_real_escape_string()</tt>. With PDO this is all taken care for us and means we no longer have to worry about SQL injection. Great.</p>
<p>The ability to easily migrate to a different database engine (SQLite, Oracle, MSSQL, ODBC, etc.) is the cherry on top of the cake.</p>
<h2>How to connect to a database</h2>
<p>Connecting is just as easy as in standard MySQL functions, it just looks slightly different. We wrap the connection attempt in a try-catch statement so we can gracefully handle errors. E.g.</p>
<pre>
try {
    $dbh = new PDO("mysql:host=localhost;dbname=my_db_table", 'username', 'password');
} catch(PDOException $e) {
    echo $e-&gt;getMessage();
}
</pre>
<p>One thing I always do is instantly tell PDO I want associative arrays returned. I prefer them to objects, but your milage may vary. I also say that we want to deal exclusively in UTF8.</p>
<pre lang="php">
// Connection string, UTF-8 encoding, and fetch associative arrays
$dbh = new PDO("mysql:host=localhost;dbname=my_db_table;charset=utf8", 'username', 'password');
$dbh-&gt;setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);
</pre>
<h2>Inserting rows</h2>
<p>Finally, some database interaction which lets us use the benefit of PDO &#8211; prepared statements. Essentially we insert placeholders into our SQL and define a value for those outside the statement. We do not, I repeat, we do not ever place user input directly into the SQL. This is susceptible to SQL injection.</p>
<p>Secondly, there are two ways to define these placeholders in your SQL statement: Positional and Named. You only ever want to use Named placeholders. Positional are, quite frankly, a silly idea. Positional placeholders ultimately will end up in inserting data in the wrong columns, or selecting data using an incorrect parameter. I&#8217;m only going to show you the correct way (in my opinion) so as to not give you bad habits.</p>
<pre>
// Define the SQL with named placeholders
$sth = $dbh-&gt;prepare("INSERT INTO `table` (`id`, `title`) VALUES (:id, :title)");

// Execute the query, replacing the placeholders with their true value
$sth-&gt;execute(array(
    ':id'    =&gt; 123,
    ':title' =&gt; 'I am the title'
));
</pre>
<p>You can see that we create a variable <tt>$sth</tt> (statement handler) which calls the <tt>$dbh</tt> (database handler) prepare method. The SQL should look pretty standard until we reach the <tt>:id</tt> and <tt>:title</tt>. These are our named placeholders. We can run this query by calling the <tt>execute()</tt> function which takes an array of the placeholder data. Quite simple.</p>
<p>The benefits of this are that our data is automatically escaped &#8211; we do not have to worry about calling <tt>mysql_real_escape_string()</tt>, after all we might not be using MySQL. Also, the benefits are that we can call the <tt>execute()</tt> functions many times without re-declaring the SQL statement, which will speed up our code execution.</p>
<pre>
// Insert three rows into the table
$sth-&gt;execute(array(':id' =&gt; 123, ':title' =&gt; 'First title'));
$sth-&gt;execute(array(':id' =&gt; 456, ':title' =&gt; 'Second title'));
$sth-&gt;execute(array(':id' =&gt; 789, ':title' =&gt; 'Third title'));
</pre>
<h2>Selecting</h2>
<p>Now that you have just mastered inserting data, selecting is a piece of cake, it&#8217;s very similar, and also gives us a chance to go over a few new functions.</p>
<pre>
// Select some data
$sth = $dbh-&gt;prepare("SELECT `id`, `title` FROM `table` WHERE `id` &gt; :country_id");

// Execute the query, replacing the placeholders with their true value
$sth-&gt;execute(array(
    ':country_id' =&gt; 200
));

// How many records did we find?
echo 'We found ' . $sth-&gt;rowCount() . ' records.';

// Loop over the data
while ($row = $sth-&gt;fetch()) {
    echo 'My ID is ' . (int)$row['id'] . ' and my title is ' . htmlentities($row['title']);
}
</pre>
<p>To get the number of rows returned you can use the <tt>rowCount()</tt> function (akin to the <tt>mysql_num_rows()</tt>), and to loop over the data you can use the <tt>fetch()</tt> function (akin to the <tt>mysql_fetch_assoc()</tt>). If you wanted to return all of the rows into a variable without performing a loop you can do <tt>fetchAll()</tt>. Otherwise there are no gotcha&#8217;s here.</p>
<h2>Updating data</h2>
<p>You&#8217;re going to be bored of me saying this, but there is nothing different here than the previous examples:</p>
<pre>
// Update a row
$sth = $dbh-&gt;prepare("UPDATE `table` SET `title` = :title WHERE `id` = :id LIMIT 1");

// Execute the query, replacing the placeholders with their true value
$sth-&gt;execute(array(
    ':title' =&gt; 'I am the newly updated title',
    ':id'    =&gt; 123
));

// Did we manage to update the row?
if ($sth-&gt;rowCount() &gt;= 1) {
    echo 'Yup, the row was updated.';
} else {
    echo 'Nope, row was not updated.';
}
</pre>
<h2>Deleting data</h2>
<p>Again, nothing too complex:</p>
<pre>
// Delete a row
$sth = $dbh-&gt;prepare("DELETE FROM `table` WHERE `id` = :id LIMIT 1");

// Execute the query, replacing the placeholders with their true value
$sth-&gt;execute(array(
    ':id' =&gt; 123
));

// Did we manage to delete the row?
if ($sth-&gt;rowCount() &gt;= 1) {
    echo 'Yup, the row was deleted.';
} else {
    echo 'Nope, row was not deleted.';
}
</pre>
<h2>Binding params, and execution</h2>
<p>This comes down to preference. I prefer the <tt>execute()</tt> because we are avoiding function calls, speeding up our code, and easier to update. But I&#8217;ll go over all three.</p>
<p><tt>bindParam()</tt> is asking for a reference. It is not asking for an immediate value, it only receives the value once the execute() function is called. This is probably the most confusing aspect of PDO, so let me give you an example.</p>
<pre>
// Select some data
$sth = $dbh-&gt;prepare("SELECT `id`, `title` FROM `table` WHERE `id` &gt; :country_id");

// Set binds
$sth-&gt;bindParam(':id', $tableId);

// Define variables
$tableId = 123;

// Execute
$sth-&gt;execute();
</pre>
<p>This works because, although <tt>$tableId</tt> does not exist when referenced, it is defined before our <tt>execute()</tt> call. The reason I do not like this is because it is leaving an uncertainty to the statement. You could quite easily bind the parameter, then change the variable for some reason and cause an error. You also have the problem that literals can not be used since they cannot be referenced. So, <tt>bindParam(':id', 123)</tt> would result in an error.</p>
<p><tt>bindValue()</tt> to the rescue! This works in the same way as <tt>bindParam()</tt>, but it uses the value straight away, be it a literal or a variable.</p>
<p><tt>execute()</tt> is what we have been using in the previous code samples, so does not need an introduction.</p>
<h2>The same thing three times?</h2>
<p><tt>exec()</tt>, <tt>execute()</tt>, and <tt>query()</tt></p>
<p>These all do the same thing, run a query. But they do so in different ways. In my opinion you should only ever use <tt>execute()</tt> as it is the only one which works with prepared statements which, in time, the other two can become susceptible to SQL injection. They also have their nuances, <tt>exec()</tt> can only be used for queries that do not return data objects (e.g., SELECT statements), and generally speaking <tt>query()</tt> is only used on SELECT statements. But since you cannot use prepared statements (e.g., placeholders), I wouldn&#8217;t bother with them.</p>
<h2>Wrapup</h2>
<p>You now know the basics of PDO. You can see it isn&#8217;t a scary monster and it really is easy to switch. You now know how to insert, select, update, and delete rows. You know how to safely pass in parameters using placeholders (remember, named not positional!) and so you now never have to worry about SQL injection.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>jQuery plugin: Handsontable</title>
		<link>http://www.chrisjhill.co.uk/article/jquery-plugin-handsontable</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Tue, 10 Jul 2012 20:57:01 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1048</guid>

					<description><![CDATA[Handsontable is a minimalistic approach to Excel-like table editor in HTML &#038; jQuery. Now with column and row headers!]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Handsontable is a minimalistic approach to Excel-like table editor in HTML &#038; jQuery. Now with column and row headers!</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>jQuery plugin: Morris.js</title>
		<link>http://www.chrisjhill.co.uk/article/jquery-plugin-morris-js</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Tue, 10 Jul 2012 08:03:28 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1046</guid>

					<description><![CDATA[Making good-looking graphs shouldn&#8217;t be hard. Morris.js is a lightweight library that uses jQuery and Raphaël to make drawing time-series graphs easy.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Making good-looking graphs shouldn&#8217;t be hard. Morris.js is a lightweight library that uses jQuery and Raphaël to make drawing time-series graphs easy.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>jQuery plugin: Turn.js</title>
		<link>http://www.chrisjhill.co.uk/article/jquery-plugin-turn-js</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Tue, 10 Jul 2012 08:02:49 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1044</guid>

					<description><![CDATA[Turn.js is a JavaScript library that will make your content look like a real book or magazine using all the advantages of HTML5. The web is getting beautiful with new user interfaces based in HTML5; turn.js is the best fit for a magazine, book or catalog based in HTML5.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Turn.js is a JavaScript library that will make your content look like a real book or magazine using all the advantages of HTML5. The web is getting beautiful with new user interfaces based in HTML5; turn.js is the best fit for a magazine, book or catalog based in HTML5.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Try Git in your browser</title>
		<link>http://www.chrisjhill.co.uk/article/try-git-in-your-browser</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Wed, 04 Jul 2012 15:58:36 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1042</guid>

					<description><![CDATA[Git allows groups of people to work on the same documents (often code) at the same time, and without stepping on each other&#8217;s toes. It&#8217;s a distributed version control system.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Git allows groups of people to work on the same documents (often code) at the same time, and without stepping on each other&#8217;s toes. It&#8217;s a distributed version control system.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Brackets: The Open Source Code Editor for the Web</title>
		<link>http://www.chrisjhill.co.uk/article/brackets-the-open-source-code-editor-for-the-web</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Sun, 01 Jul 2012 12:39:10 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1036</guid>

					<description><![CDATA[Brackets is a new open source project founded by Adobe to push tooling on the web forward. Based on the principle that the best developers to build tools for web developers are in fact web developers, Brackets is built in JavaScript, HTML and CSS.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Brackets is a new open source project founded by Adobe to push tooling on the web forward. Based on the principle that the best developers to build tools for web developers are in fact web developers, Brackets is built in JavaScript, HTML and CSS.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Update: Reversi board game in PHP and Javascript</title>
		<link>http://www.chrisjhill.co.uk/article/reversi-board-game-made-in-php</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Fri, 29 Jun 2012 13:00:51 +0000</pubDate>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1017</guid>

					<description><![CDATA[I like playing the occasional game of <a href="http://en.wikipedia.org/wiki/Reversi">Reversi</a>, and thought it would prove to be an interesting project (creating something like <a href="http://www.redhotpawn.com/">RedHotPawn</a> for chess). Several hours programming later I had a simple working prototype. A couple more hours later I added in some missing features and smartened everything up.]]></description>
										<content:encoded><![CDATA[<p>I like playing the occasional game of <a href="http://en.wikipedia.org/wiki/Reversi">Reversi</a>, and thought it would prove to be an interesting project (creating something like <a href="http://www.redhotpawn.com/">RedHotPawn</a> for chess). Several hours programming later I had a simple working prototype. A couple more hours later I added in some missing features and smartened everything up.</p>
<h2>Demonstration and Download</h2>
<p><a href="http://laboratory.chrisjhill.co.uk/reversi/">To view a demonstration of the code in action, click here.</a></p>
<p><a href="https://github.com/chrisjhill/Reversi">You can view the Github repository here.</a></p>
<h2>The PHP backend</h2>
<p>This type of program is often used in online games like <a href="https://www.daisyslots.com/all-games/slots/action-bank/">action bank</a> slots and GoBonanza. It is designed to be flexible &#8212; it can handle boards of any size and will place the starting 4 disks in the center. The PHP is also very quick &#8212; the size of the board does not really effect the performance due to the way its programmed. It only allows legal moves to be played, each move needs to flip at least one of your opponents disks, if you play an invalid move it will give you the option to skip your play.</p>
<h2>A quick snippet of the traversing function in the PHP class</h2>
<pre>
&lt;?php
/**
 * Traverse the board to see if we can take any of our opponants disks.
 *
 * To traverse the board we can add, substract, or do nothing with each X and Y coord.
 * Keep traversing until we reach an empty position, a wall, or our own disk. Once
 * reached an end, traverse back down the coords replacing the disks with our own.
 *
 * @param $xDiff int
 * @param $yDiff int
 * @access private
 */
public function doTraverse($xDiff, $yDiff) {
    // Set variables
    $x = $this-&gt;_x;
    $y = $this-&gt;_y;
    $continue = true;
    
    // Begin the loop
    do {
        // Work out the new coords to test
        $x += $xDiff;
        $y += $yDiff;
        
        // What is in the next position?
        $next = isset($this-&gt;_boardContent[$y][$x])
            ? $this-&gt;_boardContent[$y][$x]
            : 'e'; // Edge

        // Have we hit an edge or an empty position?
        if ($next == 'e' || $next == '-') {
            $continue = false;
        }
        
        // Have we reached our own disk colour?
        else if ($next == $this-&gt;_turnInPlay) {
            // We are currently at our own disk, move back one so we are at our
            // .. last free (potentially) disk.
            if ($xDiff &gt; 0) { $x--; } else if ($xDiff &lt; 0) { $x++; }
            if ($yDiff &gt; 0) { $y--; } else if ($yDiff &lt; 0) { $y++; }
            
            // Are we where we started?
            while ($x != $this-&gt;_x || $y != $this-&gt;_y) {
                // Change this disk to the player who just moved
                $this-&gt;_boardContent[$y][$x] = $this-&gt;_turnInPlay;
                
                // Set the number of disks this flipped
                $this-&gt;_disksFlipped++;
                
                // Move back one coord to begin another replacement
                if ($xDiff &gt; 0) { $x--; } else if ($xDiff &lt; 0) { $x++; }
                if ($yDiff &gt; 0) { $y--; } else if ($yDiff &lt; 0) { $y++; }
            }
            
            // We have converted all of the possible disks, exit the traverse
            $continue = false;
        }
    } while ($continue);
}
</pre>
<h2>The Javascript frontend</h2>
<p>Javascript provides a real-time view of what disks will be flipped. The traversing function is a virtual copy of the PHP classes.</p>
<h2>Functionality to be built</h2>
<p>One piece of functionality that is really needed is ensuring a legal move is actually possible. If it isn&#8217;t then it automatically skips to the next player, and if that player cannot play a legal move either then it ends the game. I&#8217;m not sure if it will be best to implement this in either PHP or Javascript &#8212; both options have their benefits.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>jQuery version 1.9 and beyond</title>
		<link>http://www.chrisjhill.co.uk/article/jquery-version-1-9-and-beyond</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Fri, 29 Jun 2012 10:29:02 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1015</guid>

					<description><![CDATA[Seems as though the jQuery team are planning on dropping support for IE 6/7/8 in jQuery 2.0, expected to be released in early 2013. Now, although I don&#8217;t particularly like IE, I think that might be a little too aggressive a development path. Unfortunately few people still use IE 6, a little more 7, and [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Seems as though the jQuery team are planning on dropping support for IE 6/7/8 in jQuery 2.0, expected to be released in early 2013. Now, although I don&#8217;t particularly like IE, I think that might be a little too aggressive a development path. Unfortunately few people still use IE 6, a little more 7, and quite a chunk 8.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Node 0.8.0 released</title>
		<link>http://www.chrisjhill.co.uk/article/node-0-8-0-released</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Mon, 25 Jun 2012 21:00:53 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1013</guid>

					<description><![CDATA[I am thrilled to announce the arrival of a new stable version of Node.js. Compared with the v0.6 releases of Node, this release brings significant improvements in many key performance metrics, as well as cleanup in several core APIs,]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>I am thrilled to announce the arrival of a new stable version of Node.js. Compared with the v0.6 releases of Node, this release brings significant improvements in many key performance metrics, as well as cleanup in several core APIs,</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>&#8216;Twisted light&#8217; carries 2.5 terabits of data per second</title>
		<link>http://www.chrisjhill.co.uk/article/twisted-light-carries-2-5-terabits-of-data-per-second</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Mon, 25 Jun 2012 15:18:44 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=1011</guid>

					<description><![CDATA[Researchers have clocked light beams made of &#8220;twisted&#8221; waves carrying 2.5 terabits of data &#8211; the capacity of more than 66 DVDs &#8211; per second.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Researchers have clocked light beams made of &#8220;twisted&#8221; waves carrying 2.5 terabits of data &#8211; the capacity of more than 66 DVDs &#8211; per second.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>PHP sockets with Ratchet</title>
		<link>http://www.chrisjhill.co.uk/article/php-sockets-with-ratchet</link>
		
		<dc:creator><![CDATA[Christopher Hill]]></dc:creator>
		<pubDate>Fri, 22 Jun 2012 08:14:50 +0000</pubDate>
				<category><![CDATA[Fragment]]></category>
		<guid isPermaLink="false">http://www.chrisjhill.co.uk/?p=991</guid>

					<description><![CDATA[Ratchet is a component library for PHP that provides developers with the tools to create real time, bi-directional applications between clients and servers. This is not your Grandfather&#8217;s Internet.]]></description>
										<content:encoded><![CDATA[<blockquote>
<p>Ratchet is a component library for PHP that provides developers with the tools to create real time, bi-directional applications between clients and servers. This is not your Grandfather&#8217;s Internet.</p>
</blockquote>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
