Loading…

How we can set the html contents of an element in jQuery?

The HTML() method is utilized to set content. It overwrites the whole content for the matched elements.

Example

                                        

$('#IDNAME').html('<p>Best Interview Question</p>');

Suggest An Answer

No suggestions avaliable!

Latest post from JQuery interview questions

Ask Question