var id = 'test';
var dom = $('#loader').clone().load("Views/chatBox.html");
dom.find('span.bn').text(id);
in chatBox.html, c'è:
...
<span class="bn">AAA</span>
...
voglio sostituire "AAA" con "test", ma non è riuscito (dom.find non può prenderlo), che significa che non è disponibile immediatamente.
Come si fa nel modo giusto?
prova a usare firebug in firefox e vedi se emette un errore. – yoda
Nessun errore, quando $ .find non riesce a trovare nulla, andrà avanti. – omg