Note that there are some explanatory texts on larger screens.

plurals
  1. POHide/Show TextBox issue using JQuery
    text
    copied!<p>i am displaying a textbox(Suppose A) when there is a focus on textbox(Suppose B) and hiding when focus is out.it is working well.I want to enter something in Box A,but it gets hide when focus is out from B.Here i want like this. if something is typed in B,A should not hide even focus is then out from B. This is my jQuery code.</p> <pre><code> $('#lastname').focusin(function () { $('input.hidden').fadeIn(1000); $('input.hidden').css('backgroundColor', 'yellow'); }).focusout(function () { $('input.hidden').hide(); }); </code></pre> <p>This is Html Code.</p> <pre><code> &lt;table&gt; &lt;tr&gt; &lt;td&gt; &lt;label&gt;First Name&lt;/label&gt;&lt;/td&gt; &lt;td&gt; &lt;input class="required" type="text" name="firstname" id="firstname" /&gt;&lt;span&gt;(required)&lt;/span&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;&lt;br/&gt;&lt;label for="lastname"&gt;Last Name&lt;/label&gt;&lt;/td&gt; &lt;td&gt;&lt;input class="required" type="text" name="lastname" id="lastname"/&gt;&lt;span&gt;(required)&lt;/span&gt;&lt;/td&gt; &lt;%-- &lt;td&gt;&lt;br/&gt;&lt;label&gt;Invisible&lt;/label&gt;&lt;/td&gt;--%&gt; &lt;td&gt;&lt;input class="hidden" type="text" name="invisible" value="Middle Name" id="invisible"/&gt;&lt;span&gt;(required)&lt;/span&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;&lt;br/&gt;&lt;label&gt;Address&lt;/label&gt;&lt;/td&gt; &lt;td&gt;&lt;input class="required" type="text" name="address" id="address"/&gt;&lt;span&gt;(required)&lt;/span&gt;&lt;/td&gt; &lt;/tr&gt; &lt;/table&gt; </code></pre> <p>Thanks in advance.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload