JavaScript Problem in Firefox 4.0
<p>I have some problem regarding JavaScript compatibility. I am using below code to clean text box blur data when click on that Text Box.This code is working fine in Firefox 3.6 &amp; IE, but not supportable on Firefox 4. Some errors are there in error console like <code>clearTextFrom is not defined</code> &amp; <code>clearTextTo is not define</code>. Please check below code &amp; suggest me how can i run this code on FF4.</p>

<pre><code>function clearTextFrom() {
    if(document.getElementById("size_from").value=="From Year")
        document.getElementById("size_from").value="";
}

function clearTextTo() {
    if(document.getElementById("size_to").value=="To Year")
        document.getElementById("size_to").value="";
}
</code></pre>

<p>Waiting for your quick response.</p>

<p>Thanks in Advance
Tanu</p>

<p>EDIT:</p>

<pre><code>&lt;div class="yearsearch"&gt; 
&lt;input type='text' style='width: 60px;' name='size_from' maxlength='4' size='17' id='size_from' onfocus='clearTextFrom();' onkeyup="validNumbers(document.getElementById('size_from')); sync();"/&gt; 
&lt;input type='text' style='width: 60px;' name='size_to' maxlength='4' size='17' id='size_to' onfocus='clearTextTo();' onkeyup="validNumbers(document.getElementById('size_to'));"/&gt;
&lt;/div&gt; 
</code></pre>

<p>This is the code which i am using to call these functions.</p>
