javascript - How to remove a div's content with jQuery -


how go removing content inside div tag class content.

<div class="content"></div> 

i imagine like:

$(.content).remove 

separately, how go adding string of text inside same div?

use .empty() remove contents in div tag.

$('.content').empty(); 

for second question; can add text or content using $('.content').html(newcontent) or

$('.content').text(newcontenttext); //specifically text content. 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -