<?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>Code Couch &#187; Firefox</title>
	<atom:link href="http://www.codecouch.com/tag/firefox/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.codecouch.com</link>
	<description>The ramblings of two code monkeys</description>
	<lastBuildDate>Mon, 09 Jan 2012 21:11:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Spell checking in Firefox</title>
		<link>http://www.codecouch.com/2008/12/spell-checking-in-firefox/</link>
		<comments>http://www.codecouch.com/2008/12/spell-checking-in-firefox/#comments</comments>
		<pubDate>Wed, 10 Dec 2008 21:07:05 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[spell]]></category>

		<guid isPermaLink="false">http://www.codecouch.com/?p=233</guid>
		<description><![CDATA[Want to know how to spell check an entire web page in Firefox? Or how to add spell-checking to fields that do not have it by default? Read on for more.]]></description>
			<content:encoded><![CDATA[<p>A handy tip I came across the other day was how to spell-check an entire web page using Firefox &#8211; not just textarea elements.</p>
<p>You basically put the page into design mode &#8211; so the content becomes editable. Enter this in the URL bar:</p>

<div class="wp_syntax_outer"><div class="wp_syntax"><div class="wp_syntax_inner"><pre class="javascript">javascript<span class="sy0">:</span><span class="kw1">void</span><span class="br0">&#40;</span>document.<span class="me1">designMode</span><span class="sy0">=</span><span class="st0">'on'</span><span class="br0">&#41;</span><span class="sy0">;</span></pre></div></div></div>

<p>You can also add spell checking to fields which do not have it by default (e.g. single-line input elements) by adding a &#8220;spellcheck&#8221; attribute set to &#8220;true&#8221;, e.g.:</p>

<div class="wp_syntax_outer"><div class="wp_syntax"><div class="wp_syntax_inner"><pre class="html4strict"><span class="sc2">&lt;<span class="kw2">input</span> <span class="kw3">type</span><span class="sy0">=</span><span class="st0">&quot;text&quot;</span> <span class="kw3">size</span><span class="sy0">=</span><span class="st0">&quot;50&quot;</span> spellcheck<span class="sy0">=</span><span class="st0">&quot;true&quot;</span>&gt;</span></pre></div></div></div>

<p>See <a href="https://developer.mozilla.org/en/Controlling_spell_checking_in_HTML_forms">https://developer.mozilla.org/en/Controlling_spell_checking_in_HTML_forms</a> for more information.</p>
<div class="tweetthis" style="text-align:left;"><p> <a target="_blank" rel="nofollow" class="tt" href="http://twitter.com/intent/tweet?text=Spell+checking+in+Firefox+http%3A%2F%2Fis.gd%2FBprV03" title="Post to Twitter"><img class="nothumb" src="http://www.codecouch.com/wp-content/plugins/tweet-this/icons/en/twitter/tt-twitter-big4.png" alt="Post to Twitter" /></a></p></div>]]></content:encoded>
			<wfw:commentRss>http://www.codecouch.com/2008/12/spell-checking-in-firefox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixing a disappearing caret in Firefox</title>
		<link>http://www.codecouch.com/2008/10/fixing-a-disappearing-caret-in-firefox/</link>
		<comments>http://www.codecouch.com/2008/10/fixing-a-disappearing-caret-in-firefox/#comments</comments>
		<pubDate>Sun, 19 Oct 2008 12:45:53 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[Browsers]]></category>
		<category><![CDATA[Firefox]]></category>

		<guid isPermaLink="false">http://www.codecouch.com/?p=178</guid>
		<description><![CDATA[The disappearing caret issue in Firefox is very annoying. There are many variations of this bug, most with fixes or workarounds. This fix is for the case where input elements on top of a fixed element do not have a caret.]]></description>
			<content:encoded><![CDATA[<p>There are many issues with Firefox hiding the caret (cursor) in text fields which have focus. There are various fixes, depending on the specifics of your issue, which mostly involve adding a style of &#8220;overflow:auto&#8221; to the input or container in question.</p>
<p>There is one case that doesn&#8217;t appear to have a fix, other than upgrading to Firefox 3: <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=230701">The cursor (caret) in a text input turns invisible when it is over a fixed element</a>. I&#8217;ve known about this problem for a while, and have tried many solutions that fixed similar issues, but they never seemed to work for this specific one.</p>
<p>I&#8217;ve found a solution that works, but it has 2 drawbacks:</p>
<ol>
<li>It requires JavaScript to work</li>
<li>It causes rendering errors on the fixed element when scrolling (almost as if the fixed element is scrolling as well)</li>
</ol>
<p>Using the test harness below, you can see the problem and the fix. I&#8217;ve included my test background image after the code, to make the rendering problem very obvious.</p>

<div class="wp_syntax_outer"><div class="wp_syntax"><div class="wp_syntax_inner"><pre class="html4strict"><span class="sc0">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;</span>
<span class="sc2">&lt;<span class="kw2">html</span> xmlns<span class="sy0">=</span><span class="st0">&quot;http://www.w3.org/1999/xhtml&quot;</span> <span class="kw3">dir</span><span class="sy0">=</span><span class="st0">&quot;ltr&quot;</span> <span class="kw3">lang</span><span class="sy0">=</span><span class="st0">&quot;en-US&quot;</span>&gt;</span>
<span class="sc2">&lt;<span class="kw2">head</span> <span class="kw3">profile</span><span class="sy0">=</span><span class="st0">&quot;http://gmpg.org/xfn/11&quot;</span>&gt;</span>
	<span class="sc2">&lt;<span class="kw2">meta</span> <span class="kw3">http-equiv</span><span class="sy0">=</span><span class="st0">&quot;content-type&quot;</span> <span class="kw3">content</span><span class="sy0">=</span><span class="st0">&quot;text/html; charset=UTF-8&quot;</span> <span class="sy0">/</span>&gt;</span>
	<span class="sc2">&lt;<span class="kw2">meta</span> <span class="kw3">http-equiv</span><span class="sy0">=</span><span class="st0">&quot;content-language&quot;</span> <span class="kw3">content</span><span class="sy0">=</span><span class="st0">&quot;en&quot;</span> <span class="sy0">/</span>&gt;</span>
	<span class="sc2">&lt;<span class="kw2">title</span>&gt;</span>Disappearing caret bug - workaround<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">title</span>&gt;</span>
&nbsp;
	<span class="sc2">&lt;<span class="kw2">style</span> <span class="kw3">type</span><span class="sy0">=</span><span class="st0">&quot;text/css&quot;</span>&gt;</span>
		#fixedDiv {
			width: 100%;
			height: 100%;
			top: 0px;
			left: 0px;
			background: url(caretBugBg.gif);
			position: fixed;
		}
&nbsp;
		#contentDiv {
			position: relative;
		}
	<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">style</span>&gt;</span>
&nbsp;
	<span class="sc2">&lt;<span class="kw2">script</span> <span class="kw3">type</span><span class="sy0">=</span><span class="st0">&quot;text/javascript&quot;</span>&gt;</span>
		function fixCaretBug() {
			document.getElementById('fixedDiv').style.zIndex = -1;
			setTimeout(fixCaretBugPartTwo, 0);
		}
&nbsp;
		function fixCaretBugPartTwo() {
			document.getElementById('fixedDiv').style.zIndex = 0;
		}
	<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">script</span>&gt;</span>
<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">head</span>&gt;</span>
&nbsp;
<span class="sc2">&lt;<span class="kw2">body</span>&gt;</span>
	<span class="sc2">&lt;<span class="kw2">div</span> <span class="kw3">id</span><span class="sy0">=</span><span class="st0">&quot;fixedDiv&quot;</span>&gt;&lt;<span class="sy0">/</span><span class="kw2">div</span>&gt;</span>
&nbsp;
	<span class="sc2">&lt;<span class="kw2">div</span> <span class="kw3">id</span><span class="sy0">=</span><span class="st0">&quot;contentDiv&quot;</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">form</span>&gt;</span>
			<span class="sc2">&lt;<span class="kw2">input</span> <span class="kw3">type</span><span class="sy0">=</span><span class="st0">&quot;text&quot;</span> <span class="kw3">size</span><span class="sy0">=</span><span class="st0">&quot;50&quot;</span> <span class="kw3">value</span><span class="sy0">=</span><span class="st0">&quot;You cannot see the caret in this text input field...&quot;</span> <span class="sy0">/</span>&gt;</span>
			<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
			<span class="sc2">&lt;<span class="kw2">input</span> <span class="kw3">type</span><span class="sy0">=</span><span class="st0">&quot;button&quot;</span> <span class="kw3">value</span><span class="sy0">=</span><span class="st0">&quot;Click me to fix that!&quot;</span> <span class="kw3">onclick</span><span class="sy0">=</span><span class="st0">&quot;fixCaretBug();&quot;</span> <span class="sy0">/</span>&gt;</span>
		<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">form</span>&gt;</span>
&nbsp;
		<span class="sc2">&lt;<span class="kw2">p</span>&gt;</span>This text...<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">p</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
&nbsp;
		<span class="sc2">&lt;<span class="kw2">p</span>&gt;</span>is used...<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">p</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
&nbsp;
		<span class="sc2">&lt;<span class="kw2">p</span>&gt;</span>to produce a vertical scrollbar.<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">p</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
&nbsp;
		<span class="sc2">&lt;<span class="kw2">p</span>&gt;</span>If you cannot see a vertical scrollbar,<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">p</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
&nbsp;
		<span class="sc2">&lt;<span class="kw2">p</span>&gt;</span>reduce the size of your browser window.<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">p</span>&gt;</span>
		<span class="sc2">&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;&lt;<span class="kw2">br</span> <span class="sy0">/</span>&gt;</span>
	<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">div</span>&gt;</span>
&nbsp;
<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">body</span>&gt;</span>
<span class="sc2">&lt;<span class="sy0">/</span><span class="kw2">html</span>&gt;</span></pre></div></div></div>

<p>There is a small flicker when the fix is enabled, although this could potentially be fixed by hooking into the DOMContentLoaded event and running the fix before the background image is loaded.</p>
<div id="attachment_182" class="wp-caption" style="width:300px;"><div style="font-size:0px;"><a href="http://www.codecouch.com/wp-content/uploads/2008/10/caretbugbg.gif"><img src="http://www.codecouch.com/wp-content/uploads/2008/10/caretbugbg-300x225.gif" alt="A grey rectangle with a black cross on top of it" title="Disappearing caret bug - workaround demo background image" width="300" height="225" class="size-medium wp-image-182" /></a></div><div class="markupPod ">
My test background image</div>
</div>
<div class="tweetthis" style="text-align:left;"><p> <a target="_blank" rel="nofollow" class="tt" href="http://twitter.com/intent/tweet?text=Fixing+a+disappearing+caret+in+Firefox+http%3A%2F%2Fis.gd%2F3Pk9fj" title="Post to Twitter"><img class="nothumb" src="http://www.codecouch.com/wp-content/plugins/tweet-this/icons/en/twitter/tt-twitter-big4.png" alt="Post to Twitter" /></a></p></div>]]></content:encoded>
			<wfw:commentRss>http://www.codecouch.com/2008/10/fixing-a-disappearing-caret-in-firefox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

