I am trying to use javascript to make text bold. I have searched the net and it seems that I can do a document.write() after I made my string bold. Isn’t there any way to perform this without opening any new page (in the same html text area)?
function bold()
{
document.write(selectedText.bold());
}
Edit: I am implementing an Text Editor and I am using a HTML TextArea, and I am trying to add all the functionality such as bold, italic, etc. I want to be able to select part of the text written and make it bold.
Something like that? Otherwise, please be more specific with your question.