What the difference between text() and html() functions in jQuery ?
$(\"#div\").html(\'Linkhello\
Use .text(…) when you intend to display the value as a simple text.
Use .html(…) when you intend to display the value as a html formatted text (or HTML content).
You should definitely use .text(...) when you’re not sure that your text (e.g. coming from an input control) do not contain characters/tags that has special meaning in HTML. This is really important because this could result in the text will not display properly but it could also cause that an unwanted JS script snippet (e.g. coming from another user input) to be activated.