Rich Text in JavaScript


问题 (Question)

I would like to display rich text to my users but I do not need to have them edit it. Is there JavaScript for a simple display of rich text?


最佳答案 (Best Answer)

You should use HTML: <p> your text here </p>

But if you really want JavaScript: document.write(" your text here ") That is assuming that you want a blank page with text.

你应该使用HTML:<p> your text here </p>

但如果你真的想让JavaScript:document.write(" your text here ")这是假设你想要一个空白页的文本。