<?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>Eric Martin &#187; Browsers</title>
	<atom:link href="http://www.ericmmartin.com/tag/browsers/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ericmmartin.com</link>
	<description></description>
	<lastBuildDate>Tue, 23 Aug 2011 13:36:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>jQuery &amp; Browser Issues (revisited)</title>
		<link>http://www.ericmmartin.com/jquery-browser-issues-revisited/</link>
		<comments>http://www.ericmmartin.com/jquery-browser-issues-revisited/#comments</comments>
		<pubDate>Fri, 06 Mar 2009 23:32:25 +0000</pubDate>
		<dc:creator>Eric Martin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Bugs]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://www.ericmmartin.com/?p=353</guid>
		<description><![CDATA[Back in August, I blogged about "three fairly significant browser issues" I had encountered while using jQuery. With the release of jQuery 1.3, and subsequent minor versions, I thought I'd take a look back at those browser issues and see if any of them had been resolved. IE7 Recap: In certain situations, jQuery’s $.browser.version will [...]]]></description>
			<content:encoded><![CDATA[<p>Back in August, I <a href="http://www.ericmmartin.com/jquery-browser-issues/">blogged</a> about "three fairly significant browser issues" I had encountered while using jQuery. With the release of jQuery 1.3, and subsequent minor versions, I thought I'd take a look back at those browser issues and see if any of them had been resolved.</p>
<p><span id="more-353"></span></p>
<h3>IE7</h3>
<p><strong>Recap:</strong> In certain situations, jQuery’s <code>$.browser.version</code> will report IE 7 as version 6.</p>
<p>Considering the problem is due to IE 7 having an incorrect user-agent, I'm not sure that this problem was up to jQuery to solve. It would have required the user-agent parsing code to check non-user-agent properties...which is probably a bad idea.</p>
<p>I found out that my original code suggestions might fail in situations where IE 6 is using a 3rd party library to add <code>XMLHttpRequest</code> support, so here are my updated IE 6 and IE 7 detection suggestions:</p>
<p>Override the <code>$.browser.version</code> value:</p>
<pre><code>jQuery.browser.version = jQuery.browser.msie &#038;&
    parseInt(jQuery.browser.version) >= 6 &#038;&
    typeof window['XMLHttpRequest'] == "object" ?
        "7.0" :
        jQuery.browser.version;</code></pre>
<p>Add a new <code>msie6</code> property:</p>
<pre><code>jQuery.browser.msie6 = jQuery.browser.msie &#038;&
    parseInt(jQuery.browser.version) == 6 &#038;&
    typeof window['XMLHttpRequest'] != "object";</code></pre>
<p>Keep in mind that <code>$.browser</code> is now deprecated, which means it will go away at some point in a future release. I'm not going to get into the object detection vs browser sniffing debate, but just be aware!</p>
<h3>Opera 9.5</h3>
<p><strong>Recap:</strong> Opera, in an effort to follow standards, changed where it was storing the value for the viewport height.</p>
<p>This issue was fixed in <a href="http://dev.jquery.com/ticket/3117">jQuery Ticket 3117</a> by <a href="http://flesler.blogspot.com/">Ariel Flesler</a>. If you have Opera 9.5, you can test the results on <a href="http://www.ericmmartin.com/code/jquery/3117/">this page</a>.</p>
<h3>Safari 3 (Windows)</h3>
<p><strong>Recap:</strong> The following element would not be hidden in Safari: <code>$("&lt;div/&gt;").hide().appendTo('body');</code></p>
<p>I found out that this issue also occurs in Safari 4! The original jQuery ticket I mentioned was marked as a duplicate, but the issue was fixed in <a href="http://dev.jquery.com/ticket/1239">ticket 1239</a>.</p>
<h3>Summary</h3>
<p>Besides the problems with the IE user-agent, the jQuery developers implemented fixes for the two other browser issues that I had previously blogged about. jQuery 1.3.x has a number of new features and code improvements and continues to be, IMO, the best available JavaScript library. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.ericmmartin.com/jquery-browser-issues-revisited/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>jQuery 1.3 and SimpleModal</title>
		<link>http://www.ericmmartin.com/jquery-13-and-simplemodal/</link>
		<comments>http://www.ericmmartin.com/jquery-13-and-simplemodal/#comments</comments>
		<pubDate>Wed, 14 Jan 2009 20:50:56 +0000</pubDate>
		<dc:creator>Eric Martin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Browsers]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[SimpleModal]]></category>

		<guid isPermaLink="false">http://www.ericmmartin.com/?p=337</guid>
		<description><![CDATA[In case you haven't heard, jQuery 1.3 has been released! In addition to being jQuery's 3rd birthday, the team has a number of new announcements, including Sizzle (a brand new CSS selector engine), a new API browser (developed by Remy Sharp) and the formation of the jQuery Foundation. I tested SimpleModal (tests and demos) with [...]]]></description>
			<content:encoded><![CDATA[<p>In case you haven't heard, jQuery 1.3 has been <a href="http://blog.jquery.com/2009/01/14/jquery-13-and-the-jquery-foundation/">released</a>! In addition to being jQuery's 3rd birthday, the team has a number of new announcements, including <a href="http://sizzlejs.com/">Sizzle</a> (a brand new CSS selector engine), a new <a href="http://api.jquery.com">API browser</a> (developed by <a href="http://remysharp.com/">Remy Sharp</a>) and the formation of the jQuery Foundation.</p>
<p>I tested <a href="http://www.ericmmartin.com/projects/simplemodal/">SimpleModal</a> (tests and demos) with jQuery 1.3 and everything seems to be working as expected. After reading about all of the speed improvements, I thought it would be interesting to run some tests (Firebug 1.3 Profiler) comparing the SimpleModal demos with jQuery 1.2.6 and jQuery 1.3:</p>
<table id="comparison">
<thead>
<tr>
<th/>
<th>Basic Modal Dialog</th>
<th>Contact Form</th>
<th>Confirm Override</th>
</tr>
</thead>
<tbody>
<tr>
<td class="heading">jQuery 1.2.6</td>
<td class="result"> 22.472ms | 1126 calls </td>
<td class="result"> 101.547ms | 3805 calls </td>
<td class="result"> 24.03ms | 1094 calls </td>
</tr>
<tr>
<td class="heading">jQuery 1.3</td>
<td class="result"> 19.747ms | 938 calls </td>
<td class="result"> 91.612ms | 3859 calls </td>
<td class="result"> 16.883ms | 914 calls </td>
</tr>
</tbody>
</table>
<p>I haven't looked into why 1.3 has more calls for the Contact Form, but even so, the execution time (ms) has improved for each one!</p>
<p>Congratulations to the jQuery team and Happy Birthday!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ericmmartin.com/jquery-13-and-simplemodal/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Google Chrome &#8211; First Impressions</title>
		<link>http://www.ericmmartin.com/google-chrome-first-impressions/</link>
		<comments>http://www.ericmmartin.com/google-chrome-first-impressions/#comments</comments>
		<pubDate>Tue, 02 Sep 2008 22:42:21 +0000</pubDate>
		<dc:creator>Eric Martin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Opinion]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.ericmmartin.com/?p=139</guid>
		<description><![CDATA[After receiving numerous "downloading" errors (0x80040508), I was finally able to install Google's new browser, Chrome. Suppressing the temptation to try out all of the new features, I jumped right in and started surfing the web. I'm actually using Chrome to type up this post and so far, everything seems to be working fine. So [...]]]></description>
			<content:encoded><![CDATA[<p>After receiving numerous "downloading" errors (0x80040508), I was finally able to install Google's new browser, <a href="http://www.google.com/chrome">Chrome</a>. </p>
<p>Suppressing the temptation to try out all of the new <a href="http://www.google.com/chrome/intl/en/features.html">features</a>, I jumped right in and started surfing the web. I'm actually using Chrome to type up this post and so far, everything seems to be working fine.</p>
<p><span id="more-139"></span></p>
<p>So far the only issue I've noticed is the rendering/handling of the <code>LEGEND</code> HTML tag inside the <code>FIELDSET</code> HTML tag. Here is a screenshot of the difference between Firefox (left) and Chrome (right):</p>
<p><img src="http://www.ericmmartin.com/wordpress/wp-content/uploads/2008/09/firefox.jpg" alt="How Firefox renders the LEGEND/FIELDSET HTML tag" title="How Firefox renders the LEGEND/FIELDSET HTML tag" width="256" /> <img src="http://www.ericmmartin.com/wordpress/wp-content/uploads/2008/09/chrome.jpg" alt="How Chrome renders the LEGEND/FIELDSET HTML tag" title="How Chrome renders the LEGEND/FIELDSET HTML tag" width="256" /></p>
<p>Note: The same rendering issue happens in Safari, so I need to determine if it is being caused by <a href="http://webkit.org/">Webkit</a> or an error in my code ;)</p>
<p>I was really interested to see if Chrome included any developer tools, similar to <a href="http://www.getfirebug.com">Firebug</a>. There is a JavaScript Console which gives you similar information to what you'd get in the Firebug Console, Net and HTML tabs. There is also a JavaScript debugger, but at this point, it looks like it is just a command line tool, so IMO, Firefox with Firebug has a clear advantage in JavaScript debugging.</p>
<p>One new feature I really like is the Task Manager. It's just like the Task Manager in Windows, except for it only displays Chrome related information. It breaks it down the Memory, CPU and Network utilization for the Browser, Tabs, and Plug-ins:</p>
<p><img src="http://www.ericmmartin.com/wordpress/wp-content/uploads/2008/09/task_manager.jpg" alt="The Chrome Task Manager" title="The Chrome Task Manager" width="468" /></p>
<p><a href="http://www.ejohn.org">John Resig</a>, Mozilla employee and jQuery creator, recently <a href="http://ejohn.org/blog/google-chrome-process-manager/">posted</a> his thoughts on the Task Manager...it certainly seems like a very useful tool.</p>
<p>For an initial release, Google Chrome seems to have a lot of promise. It will be interesting to see how this affects the current browser landscape.</p>
<p>If you've tried Chrome, I'd be interested to hear your first impressions...</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ericmmartin.com/google-chrome-first-impressions/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Run Firefox 2 and 3 simultaneously</title>
		<link>http://www.ericmmartin.com/run-firefox-2-and-3-simultaneously/</link>
		<comments>http://www.ericmmartin.com/run-firefox-2-and-3-simultaneously/#comments</comments>
		<pubDate>Thu, 28 Aug 2008 17:26:51 +0000</pubDate>
		<dc:creator>Eric Martin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Browsers]]></category>

		<guid isPermaLink="false">http://www.ericmmartin.com/?p=117</guid>
		<description><![CDATA[Despite the vast improvements in Firefox 3, I've still been using Firefox 2 because of the instability of Firebug 1.2 (beta versions). The final Firebug 1.2 version was released recently, and many of the issues have been resolved, however, I thought I'd post the steps I took to run both Firefox versions together: Download Firefox [...]]]></description>
			<content:encoded><![CDATA[<p>Despite the vast improvements in Firefox 3, I've still been using Firefox 2 because of the instability of Firebug 1.2 (beta versions). The final <a href="https://addons.mozilla.org/en-US/firefox/addon/1843">Firebug 1.2</a> version was released recently, and many of the issues have been resolved, however, I thought I'd post the steps I took to run both Firefox versions together: </p>
<p><span id="more-117"></span></p>
<h3>Download</h3>
<p><a href="http://www.mozilla.com/en-US/firefox/all-older.html">Firefox 2</a><br />
<a href="http://www.mozilla.com/en-US/firefox/all.html">Firefox 3</a></p>
<h3>Install</h3>
<p>If you already have one version installed, just install the other version, making sure to choose the Custom installation option. This will allow you to install the files into a different directory.</p>
<p>For example, if you already have Firefox 3 installed in <code>C:\Program Files\Mozilla Firefox</code>, install Firefox 2 in <code>C:\Program Files\Mozilla Firefox 2</code>. The rest of this post assumes that you are installing Firefox 2...modify as necessary.</p>
<h3>Manage Profiles</h3>
<p>From the command line, run the Profile Manager to manage your Firefox profiles:</p>
<pre><code>"C:\Program Files\Mozilla Firefox 2\firefox.exe" -profilemanager</code></pre>
<p>Create a new Profile, <code>firefox2</code> for example, and then exit the Profile Manager.</p>
<h3>Update Firefox Shortcuts</h3>
<p>Mofify the <code>Target</code> value on your shortcuts to Firefox. Right-click on the short-cut and select <code>Properties</code>. </p>
<p>For the Firefox 2 shortcut, on the <code>Shortcut</code> tab, enter:</p>
<pre><code>"C:\Program Files\Mozilla Firefox 2\firefox.exe" -no-remote -p firefox2</code></pre>
<p>Do the same for the Firefox 3 shortcut, with the following:</p>
<pre><code>"C:\Program Files\Mozilla Firefox\firefox.exe" -no-remote -p default</code></pre>
<h3>Enjoy</h3>
<p>Install <a href="https://addons.mozilla.org/en-US/firefox/addons/versions/1843#version-1.05">Firebug 1.05</a> for Firefox 2. You should now be able to run both Firefox 2 and 3 simultaneously. If you already have Firefox 2 are installing Firefox 3, just change the paths/profile names mentioned above to fit your situation.</p>
<p><strong>Caution:</strong> If you already have one version installed, use the Firefox Profile associated with it, otherwise you might loose your settings.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ericmmartin.com/run-firefox-2-and-3-simultaneously/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jQuery &amp; Browser Issues</title>
		<link>http://www.ericmmartin.com/jquery-browser-issues/</link>
		<comments>http://www.ericmmartin.com/jquery-browser-issues/#comments</comments>
		<pubDate>Wed, 13 Aug 2008 04:29:50 +0000</pubDate>
		<dc:creator>Eric Martin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Bugs]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://www.ericmmartin.com/?p=89</guid>
		<description><![CDATA[Update: This post has been replaced with an updated version. During the time that I've been using jQuery (about a year now), I've run into three fairly significant browser issues. Between IE, Firefox, Safari, and Opera, Firefox is the only browser that I have yet to experience any issues with (related to jQuery, of course). [...]]]></description>
			<content:encoded><![CDATA[<div class="note">Update: This post has been replaced with an <a href="http://www.ericmmartin.com/jquery-browser-issues-revisited/">updated version</a>.</div>
<p>During the time that I've been using jQuery (about a year now), I've run into three fairly significant browser issues. Between IE, Firefox, Safari, and Opera, Firefox is the only browser that I have yet to experience any issues with (related to jQuery, of course).</p>
<p><span id="more-89"></span></p>
<h3>IE 7</h3>
<p>In certain situations, jQuery's $.browser.version will report IE 7 as version 6. Jamie Thompson noted <a href="http://jamazon.co.uk/web/2008/07/23/an-ie7-bug-that-returns-msie-60-user-agent-string/">one possible situation</a> on his blog, but typically the issue is caused due to the fact that some copies of IE 7 included <code>MSIE 6.0</code> within its <a href="http://jamazon.co.uk/web/2008/03/14/jquerybrowserversion-doesnt-recognise-ie7/">user-agent string</a>.</p>
<p>There is a <a href="http://dev.jquery.com/ticket/3169">jQuery Ticket</a> open for the issue, but a solution has not been chosen. Based on some ideas that Jamie had, I came up with a possible solution by overriding the $.browser.version value:</p>
<pre><code>jQuery.browser.version = jQuery.browser.msie &#038;&
    parseInt(jQuery.browser.version) >= 6 &#038;&
    window["XMLHttpRequest"] ?
        "7.0" :
        jQuery.browser.version;</code></pre>
<p>Additionally, there are situations when I'm just looking for IE 6:</p>
<pre><code>jQuery.browser.msie6 = jQuery.browser.msie &#038;&
    parseInt(jQuery.browser.version) == 6 &#038;&
    !window["XMLHttpRequest"];</code></pre>
<p>It appears that these issues were resolved in IE 8 (at least in the beta version), but until jQuery releases a "fix", you'll have to deal with unreliable browser version detection in IE 7, or use one of the suggestions above.</p>
<h3>Opera 9.5</h3>
<p>I discovered an issue getting the viewport height in Opera 9.5 while testing my rewrite of <a href="http://www.ericmmartin.com/projects/simplemodal">SimpleModal</a>. It turns out that Opera, in an effort to follow standards, changed where it was storing the value for the viewport height...breaking the way jQuery was getting the value. Previously, the value was stored in <code>document.body["clientHeight"]</code>, but in 9.5 it was moved to <code>document.documentElement["clientHeight"]</code>. There is also a <a href="http://dev.jquery.com/ticket/3117">jQuery Ticket</a> open for this issue, and a patch has been added by <a href="http://flesler.blogspot.com/">Ariel Flesler</a>.</p>
<p>For SimpleModal, I've added code that will fix the issue until it is fixed in jQuery:</p>
<pre><code>// fix a jQuery/Opera bug with determining the window height
var h = $.browser.opera &#038;& $.browser.version &gt; "9.5" &#038;&
    $.fn.jquery &lt;= "1.2.6" ?
        document.documentElement["clientHeight"] :
        $(window).height();</code></pre>
<h3>Safari 3 (Windows)</h3>
<p>This is the smallest of the three issues, but annoying none-the-less. Take the following example:</p>
<pre><code>$("&lt;div/&gt;").css({
    background: "#336699",
    color: "#fff",
    padding: "8px",
    width: "200px"
}).html("Loading...").hide().appendTo("body");
</code></pre>
<p>In Safari, the "loading" element will be visible when the page loads. In all other browsers, it is hidden (<code>display:none</code>). The issue occurs because the jQuery <code>hide()</code> function is supposed to look for "visible" elements and set the CSS display property to 'none'. However, in Safari, it appears that an element not yet in the DOM, already has a display property of 'none'...which sounds fine, right? It's not! Since it fails the visibility test, jQuery does not explicitly set the display property to "none".</p>
<p>Then, once the element is added to the DOM, it appears that Safari sets the elements display property to 'block'. So even though the intention was to have it "hidden", due to a Safari quirk (and lack of a jQuery internal solution), the element will be visible.</p>
<p>As I'm sure you've guessed by now, there is a <a href="http://dev.jquery.com/ticket/2233">jQuery Ticket</a> open, but the suggestion is to just change the way you use jQuery. One suggestion is to move the <code>.hide()</code> after the <code>.appendTo("body")</code>. My problem with this is that it introduces the possibility of a flicker on the screen as the element is added and then hidden. The workaround I am using is to manually set the display property on the element:</p>
<pre><code>$("&lt;div/&gt;").css({
    background: "#336699",
    color: "#fff",
    display: "none",
    padding: "8px",
    width: "200px"
}).html("Loading...").appendTo("body");
</code></pre>
<p>That concludes my notes about three browser issues I've encountered while using jQuery. If you've run into any issues where you've had to use a workaround, or have any other suggestions for the workarounds I used, feel free to mention them below!</p>
<p>And the moral of the story...use <a href="http://www.spreadfirefox.com/node&#038;id=167004&#038;t=1">Firefox</a>! :)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ericmmartin.com/jquery-browser-issues/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

