View Single Post
Old 09-30-2012, 12:46 AM   PM User | #2
xelawho
Senior Coder

 
xelawho's Avatar
 
Join Date: Nov 2010
Posts: 2,461
Thanks: 52
Thanked 457 Times in 455 Posts
xelawho will become famous soon enoughxelawho will become famous soon enough
I guess the first question is going to be if you want it on various lines, why not use a text area:
Code:
<p class="wrap"><textarea name="definition" rows="6" cols="30" style="color:black;font-weight:bold; border-style:none; border-color: inherit; border-width:medium; background-color: Transparent; width: 200; word-wrap: break-word;">'Sed at mauris lorem, id viverra nulla. Donec egestas odio vitae felis fermentum accumsan. Integer sit amet erat tortor, eget dapibus quam.' </textarea></p>
but an even better question is why not make it a div and change its contents using innerHTML

Code:
<div id="definition" style="height:50px; width:30px; color:black;font-weight:bold; border-style:none; border-color: inherit; border-width:medium; background-color: Transparent; width: 200; word-wrap: break-word;">'Sed at mauris lorem, id viverra nulla. Donec egestas odio vitae felis fermentum accumsan. Integer sit amet erat tortor, eget dapibus quam.' </div>

...

document.getElementById("definition").innerHTML = "'Lorem ipsum dolor sit amet, etc"
xelawho is offline   Reply With Quote
Users who have thanked xelawho for this post:
taypandt (09-30-2012)