i have content in <p class='firstline'> , want display inside <p class='secondline'> possible on 1 line in jquery without using function within text() method? $('p.secondline').text($('p.firstline'));
yes, possible. can set innertext of 1 element innertext of element.
you didn't call text() in code. $('p.secondline').text($('p.firstline'));.
$('p.secondline').text($('p.firstline').text()); // ^^^^^^^
Comments
Post a Comment