06-25-2002, 10:45 AM
Which HTML tag should I use if I want to display text? But I also want to access this text dynamically by the "value" attribute and display it as readonly ? (like an input tag but without the frame around the text)
06-25-2002, 11:43 AM
<textarea readonly="readonly" style="border:0px;"></textarea>
06-25-2002, 01:10 PM
there is also use of DIVs for example
text2mod.innerHTML = "this is the new text"
this is very usefull for changing text without having a big box around it. i used this once to make a matric style typer. scared the hell out of my sister when she thought that one of her exs had nabbed the control off her computer!
06-25-2002, 01:19 PM
This was the method I was using temporarily although it's pretty useful to use and works with IE and Mozilla 1.0, I prefer to access an object by its value attribute when it's possible because of the possible HTML tags embedded in the innerHTML (<b> for example).
But thanks for your reply.