में फ़ील्ड पर फ़ोकस सेट करें गतिशील रूप से लोड किए गए DIV के भीतर किसी विशिष्ट फ़ील्ड पर फ़ोकस सेट करने का उचित तरीका क्या है?गतिशील रूप से लोड किए गए DIV
$("#display").load("?control=msgs"); // loads the HTML into the DIV
$('#display').fadeIn("fast"); // display it
$("tex#header").focus(); // ?? neither that
$("input#header").focus(); // ?? nor that
$('#display', '#header').focus() // ?? nor that
$("#header").focus(); // ?? nor that works
निम्नलिखित एचटीएमएल display
DIV में लाई गई है:
<div id="display">
<form id="newHeaderForm" class="dataform" action="/" method="post">
<input id="to" type="hidden" value="22" name="to"/>
<dl>
<dt>Header</dt>
<dd>
<input id="header" class="large" type="text" name="header" value="" maxlength="128"/>
</dd>
</form>
</div>
कई, बहुत धन्यवाद!
क्या आप हमें जेनरेट किया गया एचटीएमएल भी दिखा सकते हैं? – Bela
$ ('# display', '#header')। फोकस() – orip