2
I have a variable where it contains several HTML codes. This variable is already mounted, what I have to do is replace an attribute that is in a child div (tabindex)
. Is there a function where I can change this variable without giving each.
Inside this variable I have 2 tabindex, in which I have to change.
var div = '
<div class="teste">
Meu teste
<div class="filho" tabindex="1">
Div filho
<input type="text" class="search" tabindex="2" />
</div>
</div>';
ex:
.after(function(){
return $(div)....attr("tabindex","10");
})
I was wrong because it doesn’t put $(div) in a variable... Thank you.. ATT
– abcd