<?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>Alan J. Williams</title>
	<atom:link href="http://www.alanjwilliams.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.alanjwilliams.com</link>
	<description>Online profile</description>
	<lastBuildDate>Sat, 30 Apr 2011 11:49:14 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Mozilla Firefox, Input Radio and Label tags</title>
		<link>http://www.alanjwilliams.com/2011/03/mozilla-firefox-input-radio-and-label-tags/</link>
		<comments>http://www.alanjwilliams.com/2011/03/mozilla-firefox-input-radio-and-label-tags/#comments</comments>
		<pubDate>Tue, 15 Mar 2011 16:24:35 +0000</pubDate>
		<dc:creator>Alan</dc:creator>
				<category><![CDATA[HTML]]></category>
		<category><![CDATA[INPUT]]></category>
		<category><![CDATA[mozilla firefox]]></category>
		<category><![CDATA[RADIO]]></category>
		<category><![CDATA[weirdness]]></category>

		<guid isPermaLink="false">http://www.alanjwilliams.com/?p=11</guid>
		<description><![CDATA[Came across this anomaly today for the first time. Extending a form where the label tag defined a row with several radio buttons inside, for the basis of providing a rating system from 1-5. Rate this (1-5) In Firefox this demonstrates some weird behaviour where by if you click the 4th one, it&#8217;ll generally just [...]]]></description>
			<content:encoded><![CDATA[<p>Came across this anomaly today for the first time. Extending a form where the label tag defined a row with several radio buttons inside, for the basis of providing a rating system from 1-5.<br />
<code><br />
<label><br />
<span>Rate this (1-5)</span></p>
<input style="margin: 10px;" name="rating" type="radio" value="1" />
<input style="margin: 10px;" name="rating" type="radio" value="2" />
<input style="margin: 10px;" name="rating" type="radio" value="3" />
<input style="margin: 10px;" name="rating" type="radio" value="4" />
<input style="margin: 10px;" name="rating" type="radio" value="5" />
</label><br />
</code><br />
In Firefox this demonstrates some weird behaviour where by if you click the 4th one, it&#8217;ll generally just select the first one, unless you vehemently keep clicking to get it to the correct value. Oddly this is valid HTML and works fine in IE, Opera and Chrome (and presumably Safari).</p>
<p><span id="more-11"></span><br />
The source for this is below.</p>
<pre>&lt;label&gt;
	&lt;span&gt;Rate this (1-5)&lt;/span&gt;
	&lt;input style="margin: 10px;" name="rating" type="radio" value="1" /&gt;
	&lt;input style="margin: 10px;" name="rating" type="radio" value="2" /&gt;
	&lt;input style="margin: 10px;" name="rating" type="radio" value="3" /&gt;
	&lt;input style="margin: 10px;" name="rating" type="radio" value="4" /&gt;
	&lt;input style="margin: 10px;" name="rating" type="radio" value="5" /&gt;
&lt;/label&gt;</pre>
<p>It appears the issue is caused by having a single label tag surrounding all the radio buttons. So the correct fix is to do it per radio using the for=&#8221;&#8230;&#8221; attribute. My quick solution for my work was to close the label after my span tag and allow them to sit seperately.</p>
<p>Thanks to <a title="Stack Overflow" href="http://stackoverflow.com/questions/1619336/firefox-radio-button-weirdness" target="_blank">this</a> thread on <a title="Stack Overflow" href="http://stackoverflow.com" target="_blank">StackOverflow</a> for the solution.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.alanjwilliams.com/2011/03/mozilla-firefox-input-radio-and-label-tags/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL Example &#8211; Select different count of multiple where clauses</title>
		<link>http://www.alanjwilliams.com/2011/03/sql-example-select-different-count-of-multiple-where-clauses/</link>
		<comments>http://www.alanjwilliams.com/2011/03/sql-example-select-different-count-of-multiple-where-clauses/#comments</comments>
		<pubDate>Fri, 04 Mar 2011 15:26:13 +0000</pubDate>
		<dc:creator>Alan</dc:creator>
				<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://www.alanjwilliams.com/?p=10</guid>
		<description><![CDATA[Today I was writing a query to retrieve a number of records in a table which were associated to several different identifiers from a second table, which in turn were resolved from a third table. I had a quick look on line to see if there were any quick examples I could start the basis [...]]]></description>
			<content:encoded><![CDATA[<p>Today I was writing a query to retrieve a number of records in a table which were associated to several different identifiers from a second table, which in turn were resolved from a third table.</p>
<p>I had a quick look on line to see if there were any quick examples I could start the basis off, but most examples were for just obvious queries or single count(*) and misrepresented. So I have an example of my solution below:</p>
<pre>SELECT
	COUNT(1) as "Count",
	table2.name as "Name"
FROM table1
LEFT JOIN table2 on table2.id = table1.table2id
WHERE table1.table2id IN
(
	SELECT table2.id FROM table2 WHERE table2.field2='clause'
)
GROUP BY table2.name</pre>
<p><span id="more-10"></span><br />
This basically totals up the amount of records in table1 that match the table2.id (zero to many matches) individually. So instead of a standard</p>
<pre>COUNT(*)
67</pre>
<p>We get:</p>
<pre>Count	Name
24	name1
43	name2</pre>
<p>And so can see the total of each corresponding match there is.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.alanjwilliams.com/2011/03/sql-example-select-different-count-of-multiple-where-clauses/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New Job</title>
		<link>http://www.alanjwilliams.com/2010/10/new-job/</link>
		<comments>http://www.alanjwilliams.com/2010/10/new-job/#comments</comments>
		<pubDate>Sat, 23 Oct 2010 13:15:14 +0000</pubDate>
		<dc:creator>Alan</dc:creator>
				<category><![CDATA[Job]]></category>
		<category><![CDATA[KMP]]></category>
		<category><![CDATA[personal]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://www.alanjwilliams.com/?p=8</guid>
		<description><![CDATA[Started working at KMP Digitata this month.  The post is working as a web developer so gives me the opportunity to work with new technologies and learn more about web application servers past my previous experience with JBoss. Things are going well but once again means that personal projects are on hold, currently enjoying my [...]]]></description>
			<content:encoded><![CDATA[<p>Started working at <a title="KMP Digitata" href="http://kmp.co.uk/" target="_blank">KMP Digitata</a> this month.  The post is working as a web developer so gives me the opportunity to work with new technologies and learn more about web application servers past my previous experience with JBoss. Things are going well but once again means that personal projects are on hold, currently enjoying my free time away from the codeface!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.alanjwilliams.com/2010/10/new-job/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress</title>
		<link>http://www.alanjwilliams.com/2010/07/hello-world/</link>
		<comments>http://www.alanjwilliams.com/2010/07/hello-world/#comments</comments>
		<pubDate>Tue, 27 Jul 2010 11:05:48 +0000</pubDate>
		<dc:creator>Alan</dc:creator>
				<category><![CDATA[Site]]></category>
		<category><![CDATA[new]]></category>
		<category><![CDATA[site]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.alanjwilliams.com/?p=1</guid>
		<description><![CDATA[After development on my own site had slowed a bit, I decided to step back and use a fully fledged dedicated CMS on my domain. I&#8217;ve used WordPress before but never much enjoyed my experience of it. The back-end is a overly comprehensive and I find it to be filled with a large amount of [...]]]></description>
			<content:encoded><![CDATA[<p>After development on my own site had slowed a bit, I decided to step back and use a fully fledged dedicated CMS on my domain.</p>
<p>I&#8217;ve used WordPress before but never much enjoyed my experience of it. The back-end is a overly comprehensive and I find it to be filled with a large amount of guff that isn&#8217;t easily removed.</p>
<p>However, in the past couple of months, after dabbling in it for a client, I&#8217;ve managed to realise the potential to hack and customise the CMS to my own needs. It&#8217;s something new to work on anyway.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.alanjwilliams.com/2010/07/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

