<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: jQuery browser and OS detection plugin</title>
	<atom:link href="http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/</link>
	<description>about web development</description>
	<lastBuildDate>Fri, 03 Feb 2012 22:35:35 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Aaron</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14382</link>
		<dc:creator>Aaron</dc:creator>
		<pubDate>Wed, 27 Jul 2011 17:52:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14382</guid>
		<description>Great job! This is incredibly useful to me. I was having trouble with differences in UL spacing between Mac and Windows and this will allow me to use two different style sheets to compensate.

cheers,
aaron</description>
		<content:encoded><![CDATA[<p>Great job! This is incredibly useful to me. I was having trouble with differences in UL spacing between Mac and Windows and this will allow me to use two different style sheets to compensate.</p>
<p>cheers,<br />
aaron</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Simon Mann</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14379</link>
		<dc:creator>Simon Mann</dc:creator>
		<pubDate>Wed, 27 Jul 2011 08:18:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14379</guid>
		<description>Nice work.
I&#039;m creating an application which detects whether the OS is 32 or 64bit architecture and then offers up an installer file. The main app is a pyside qt application which can handle all the OS checking for architecture but I needed to create a browser compatible fall back. This library helped lots but I decided to mod it slightly to do some basic architecture checks.

In the init: function part I added a call:
&lt;pre lang=&quot;javascript&quot;&gt;
this.arch = this.searchString(this.dataArch) &#124;&#124; &quot;32bit&quot;;
&lt;/pre&gt;
added a new data object under dataOS:
&lt;pre lang=&quot;javascript&quot;&gt;
dataArch : [
			{
				string: navigator.userAgent,
				subString: &quot;WOW64&quot;,
				identity: &quot;64bit&quot;
			},
			{
				string: navigator.userAgent,
				subString: &quot;Win64&quot;,
				identity: &quot;64bit&quot;
			},
			{
				string: navigator.userAgent,
				subString: &quot;x64&quot;,
				identity: &quot;64bit&quot;
			},
			{
				string: navigator.userAgent,
				subString: &quot;x86_64&quot;,
				identity: &quot;64bit&quot;
			},
		],
&lt;/pre&gt;
and finally added it to the window.client call:
&lt;pre lang=&quot;javascript&quot;&gt;
window.$.client = { os : BrowserDetect.OS, browser : BrowserDetect.browser, arch : BrowserDetect.arch };
&lt;/pre&gt;
Hope it might be useful to someone :)

Si</description>
		<content:encoded><![CDATA[<p>Nice work.<br />
I&#8217;m creating an application which detects whether the OS is 32 or 64bit architecture and then offers up an installer file. The main app is a pyside qt application which can handle all the OS checking for architecture but I needed to create a browser compatible fall back. This library helped lots but I decided to mod it slightly to do some basic architecture checks.</p>
<p>In the init: function part I added a call:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">arch</span> <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">searchString</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">dataArch</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> <span style="color: #3366CC;">&quot;32bit&quot;</span><span style="color: #339933;">;</span></pre></div></div>

<p>added a new data object under dataOS:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">dataArch <span style="color: #339933;">:</span> <span style="color: #009900;">&#91;</span>
			<span style="color: #009900;">&#123;</span>
				string<span style="color: #339933;">:</span> navigator.<span style="color: #660066;">userAgent</span><span style="color: #339933;">,</span>
				subString<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;WOW64&quot;</span><span style="color: #339933;">,</span>
				identity<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;64bit&quot;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
			<span style="color: #009900;">&#123;</span>
				string<span style="color: #339933;">:</span> navigator.<span style="color: #660066;">userAgent</span><span style="color: #339933;">,</span>
				subString<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;Win64&quot;</span><span style="color: #339933;">,</span>
				identity<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;64bit&quot;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
			<span style="color: #009900;">&#123;</span>
				string<span style="color: #339933;">:</span> navigator.<span style="color: #660066;">userAgent</span><span style="color: #339933;">,</span>
				subString<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;x64&quot;</span><span style="color: #339933;">,</span>
				identity<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;64bit&quot;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
			<span style="color: #009900;">&#123;</span>
				string<span style="color: #339933;">:</span> navigator.<span style="color: #660066;">userAgent</span><span style="color: #339933;">,</span>
				subString<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;x86_64&quot;</span><span style="color: #339933;">,</span>
				identity<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;64bit&quot;</span>
			<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
		<span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span></pre></div></div>

<p>and finally added it to the window.client call:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">window.$.<span style="color: #660066;">client</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#123;</span> os <span style="color: #339933;">:</span> BrowserDetect.<span style="color: #660066;">OS</span><span style="color: #339933;">,</span> browser <span style="color: #339933;">:</span> BrowserDetect.<span style="color: #660066;">browser</span><span style="color: #339933;">,</span> arch <span style="color: #339933;">:</span> BrowserDetect.<span style="color: #660066;">arch</span> <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Hope it might be useful to someone <img src='http://www.stoimen.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Si</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: stefano</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14353</link>
		<dc:creator>stefano</dc:creator>
		<pubDate>Sun, 26 Jun 2011 05:55:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14353</guid>
		<description>@Tyler,

I&#039;ve seen a solution around I think you could use here as well. In short, you add to the html tag different CSS classes depending on &lt;em&gt;$.client.browser&lt;/em&gt; and/or &lt;em&gt;$.client.os&lt;/em&gt; and so on.
&lt;pre lang=&quot;javascript&quot;&gt;
$(document).ready(function () {
   var body = $(&quot;html&quot;);
   body.addClass($.client.browser);

   // &lt;em&gt;body.addClass($.client.os);&lt;/em&gt;
});
&lt;/pre&gt;
then you&#039;ll need a CSS with those classes with the right properties for specific browser(s) you want. For instance:

.Safari {...}    /* CSS for Safari */
.Explorer {...}  /* CSS for MSIE   */

And if also &lt;em&gt;body.addClass($.client.os);&lt;/em&gt; you need more than just one class in CSS:

.Safari.Mac {...}
.Safari.Win {...}

Hope this helps.</description>
		<content:encoded><![CDATA[<p>@Tyler,</p>
<p>I&#8217;ve seen a solution around I think you could use here as well. In short, you add to the html tag different CSS classes depending on <em>$.client.browser</em> and/or <em>$.client.os</em> and so on.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span>document<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
   <span style="color: #003366; font-weight: bold;">var</span> body <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;html&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
   body.<span style="color: #660066;">addClass</span><span style="color: #009900;">&#40;</span>$.<span style="color: #660066;">client</span>.<span style="color: #660066;">browser</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
   <span style="color: #006600; font-style: italic;">// &lt;em&gt;body.addClass($.client.os);&lt;/em&gt;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>then you&#8217;ll need a CSS with those classes with the right properties for specific browser(s) you want. For instance:</p>
<p>.Safari {&#8230;}    /* CSS for Safari */<br />
.Explorer {&#8230;}  /* CSS for MSIE   */</p>
<p>And if also <em>body.addClass($.client.os);</em> you need more than just one class in CSS:</p>
<p>.Safari.Mac {&#8230;}<br />
.Safari.Win {&#8230;}</p>
<p>Hope this helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tyler</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14328</link>
		<dc:creator>Tyler</dc:creator>
		<pubDate>Tue, 31 May 2011 21:59:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14328</guid>
		<description>How could I use this to load a different style sheet?</description>
		<content:encoded><![CDATA[<p>How could I use this to load a different style sheet?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rafael da costa</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14311</link>
		<dc:creator>rafael da costa</dc:creator>
		<pubDate>Thu, 19 May 2011 15:57:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14311</guid>
		<description>can the script be updated to detect Android os and browser versions?</description>
		<content:encoded><![CDATA[<p>can the script be updated to detect Android os and browser versions?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rafael da costa</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14310</link>
		<dc:creator>rafael da costa</dc:creator>
		<pubDate>Thu, 19 May 2011 14:42:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14310</guid>
		<description>I see you added code to detect browser version. do you have code to detect OS version as well. I need to detect os versions of mobile devices. some os versions of android do not support Typekit (Android 2.2 and higher only) and I need account for this by detecting Android 2.1</description>
		<content:encoded><![CDATA[<p>I see you added code to detect browser version. do you have code to detect OS version as well. I need to detect os versions of mobile devices. some os versions of android do not support Typekit (Android 2.2 and higher only) and I need account for this by detecting Android 2.1</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joshua</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14207</link>
		<dc:creator>Joshua</dc:creator>
		<pubDate>Tue, 22 Feb 2011 23:32:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14207</guid>
		<description>Thanks dude, this is so nice and simple.  It also compresses to 1.24KB

http://closure-compiler.appspot.com/code/jsc1a1f42dd415b9fe11d484ca9f9591418/default.js</description>
		<content:encoded><![CDATA[<p>Thanks dude, this is so nice and simple.  It also compresses to 1.24KB</p>
<p><a href="http://closure-compiler.appspot.com/code/jsc1a1f42dd415b9fe11d484ca9f9591418/default.js" rel="nofollow">http://closure-compiler.appspot.com/code/jsc1a1f42dd415b9fe11d484ca9f9591418/default.js</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Art</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14137</link>
		<dc:creator>Art</dc:creator>
		<pubDate>Thu, 30 Dec 2010 04:53:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14137</guid>
		<description>&lt;strong&gt;THANK YOU VERY MUCH!&lt;/strong&gt; Great work!</description>
		<content:encoded><![CDATA[<p><strong>THANK YOU VERY MUCH!</strong> Great work!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Celso Bessa</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14132</link>
		<dc:creator>Celso Bessa</dc:creator>
		<pubDate>Mon, 27 Dec 2010 17:48:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14132</guid>
		<description>Great and simple plugin.

I am using in a website i am doing and i will put a note in the script header about you.

Thanks!</description>
		<content:encoded><![CDATA[<p>Great and simple plugin.</p>
<p>I am using in a website i am doing and i will put a note in the script header about you.</p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Brad</title>
		<link>http://www.stoimen.com/blog/2009/07/16/jquery-browser-and-os-detection-plugin/comment-page-1/#comment-14126</link>
		<dc:creator>Brad</dc:creator>
		<pubDate>Wed, 22 Dec 2010 18:28:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.stoimen.com/blog/?p=689#comment-14126</guid>
		<description>Thank you very much for providing a complete solution!</description>
		<content:encoded><![CDATA[<p>Thank you very much for providing a complete solution!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

