Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
108
rated 0 times [  111] [ 3]  / answers: 1 / hits: 89882  / 13 Years ago, wed, march 30, 2011, 12:00:00

Does anyone know the jQuery equivalent for window.document.write('') in javascript?
Thanks


More From » jquery

 Answers
7

This will add the string hello right before the body closing tag. Not exactly the behavior of write, but you can do this to any element to get the content to appear where you want it.



$(document.body).append('hello');


Also available are prepend(content) and replaceWith(content) for all your insertion needs!


[#93011] Monday, March 28, 2011, 13 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
karleel

Total Points: 309
Total Questions: 79
Total Answers: 86

Location: Monaco
Member since Sun, Jan 16, 2022
2 Years ago
;