새소식

Front

[jQuery] how to set the text of a pre tag

  • -
728x90

ex)

1
2
3
4
5
6
html
<pre id="article"></pre>
 
script
var title = "HI THERE!"
$("#article").text(title);
cs


good luck!

reference : https://stackoverflow.com/questions/4973039/how-to-set-the-text-of-a-pre-tag-using-jquery

#pre #tag #text #query

반응형
Contents

포스팅 주소를 복사했습니다

이 글이 도움이 되었다면 공감 부탁드립니다.