<?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>I am Ad Taylor &#187; progressive enhancement</title>
	<atom:link href="http://www.iamadtaylor.com/tag/progressive-enhancement/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.iamadtaylor.com</link>
	<description>The portfolio and blog of Ad Taylor</description>
	<lastBuildDate>Thu, 20 May 2010 22:49:55 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Detecting old versions of Firefox for progressive enhancement</title>
		<link>http://www.iamadtaylor.com/detecting-old-versions-of-firefox-for-progressive-enhancement/</link>
		<comments>http://www.iamadtaylor.com/detecting-old-versions-of-firefox-for-progressive-enhancement/#comments</comments>
		<pubDate>Fri, 31 Jul 2009 10:02:51 +0000</pubDate>
		<dc:creator>Ad Taylor</dc:creator>
				<category><![CDATA[shorts]]></category>
		<category><![CDATA[browser sniffing]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[progressive enhancement]]></category>

		<guid isPermaLink="false">http://www.iamadtaylor.com/?p=176</guid>
		<description><![CDATA[CSS3 -moz-transform doesn't work in older version of Firefox. Here I show how to detect firefox browser versions using jQuery. ]]></description>
			<content:encoded><![CDATA[<p>Today I have been redesigning my CV (as you do) as I wanted it to be hosted/printed/enjoyed from my site and not as a PDF. Whilst designing it I saw a post by <a href="http://snook.ca" class="vcard fn url">Jonathan Snook</a> on <a href="http://snook.ca/archives/html_and_css/css-text-rotation">CSS text rotation</a>, this is really exciting as Jonathan also shows you how to use a filter to make it work in IE — exciting stuff.</p>
<p>I decided to use it on my CV, but whilst designing I noticed it wasn&#8217;t working in Firefox older than 3.5. This sucked. So I set about <strong>BROWSER SNIFFING</strong>. I didn&#8217;t take this decision lightly but I figured it is no different to <code>[if IE]</code> and the only difference to the code would be removing a class.</p>
<h4>jQuery to the rescue</h4>
<p>To make long story short, I used the version function in jquery. Comments are in the code:</p>
<pre>
<code>
if($.browser.firefox || $.browser.mozilla) {

 var ver = $.browser.version;

 // Take out al the full stops so we can use it
 // as an integer
 ver = ver.replace(/\./g,"");

 // As the version numbers differ in length
 // we force all numbers to be the same length.
 // This is ok as we are only interested in the
 // first couple of digits
 var verl = ver.length;
 while (verl < 7) {ver = ver + '0'; verl = ver.length;}
 ver = parseInt(ver);

 // Check to see if the browser is older that 3.5
 if(ver <= "1910000") {$("h3").removeClass('rotate');}

}</code>
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.iamadtaylor.com/detecting-old-versions-of-firefox-for-progressive-enhancement/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

