2010-06-09, 07:54 PM
ok, i have a html textarea box. Im making a link that inserts a premade posting format into the textarea.
code:
This works great. Clicking "Text1" link adds "text1" to the textarea and text2 does the same. UNTIL, I want to add multiple lines to the posting format. If I want to put
code:
function AddItem(ItemID)
{
document.form.message.value=document.form.message.value+ItemID;
document.form.message.focus();
return;
}
If you to add default text, click the following links: <a href="javascript: AddItem('text1');">Text1</a> <a href="javascript: AddItem('text2');">Text2</a>
This works great. Clicking "Text1" link adds "text1" to the textarea and text2 does the same. UNTIL, I want to add multiple lines to the posting format. If I want to put
text1:
text2:
text3:
into the <a href="javascript: AddItem('blahhhh');">blahh</a> link how would I do it?