[jQuery] Platform detection solved

[jQuery] Platform detection solved

<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">I reviewed the source and its much simpler than I thought, here is an extension to jquery that works well, and obviouslly shouldnt break other plugins<DIV><BR class="khtml-block-placeholder"></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#7F0055" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">var </SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">userOSAgent = navigator.userAgent.toLowerCase();</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 11px/normal Monaco; min-height: 15px; "><BR></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#3F5FBF" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">// Figure out what browser is being used</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">jQuery.platform = </SPAN></FONT><FONT class="Apple-style-span" color="#7F0055" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">{</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre"> </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">mac: /mac/.test(userOSAgent),</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre"> </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">osx: /mac os x/.test(userOSAgent),</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre"> </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">win: /win/.test(userOSAgent),</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><SPAN class="Apple-tab-span" style="white-space:pre"> </SPAN><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">linux: /linux/.test(userOSAgent)</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#7F0055" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">}</SPAN></FONT><FONT class="Apple-style-span" face="Monaco" size="3"><SPAN class="Apple-style-span" style="font-size: 11px;">;</SPAN></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><BR class="khtml-block-placeholder"></DIV></BODY></HTML>