Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to clear innerhtml in javascript

//Using jQuery.
$('.myElement').empty();

//Using Vanila JS
document.querySelector('.myElement').innerHTML = '';
 
PREVIOUS NEXT
Tagged: #clear #innerhtml #javascript
ADD COMMENT
Topic
Name
1+1 =