Click to See Complete Forum and Search --> : n00b help! :D


mg8
08-28-2003, 07:23 AM
<input type="text" size="50" Maxlength="50" value="">

Using a form, I want the person to type the name into the textbox. However, I want to save what they wrote so I can use it later on in the form. How do I do this/

Thanks

Fang
08-28-2003, 07:48 AM
You can refer to it:
document.FormName.ElementName.value

mg8
08-28-2003, 01:28 PM
<input type="hidden" name="message_subject" value=document.frmMain.name.value" gets a shoutout!">

Now, that doesn't work. How do I incorporate it back into the value part? I want to put what they typed where the document.frmMain.name.value is located.

Fang
08-29-2003, 01:09 AM
Not the place to put it:

<input type="text" size="50" Maxlength="50" value="" onblur="document.frmMain.message_subject.value=this.value;">

mg8
08-29-2003, 05:20 AM
Cool! :)

Also, I want to reput it in:

<input type="hidden" name="message_subject" value=this.value" gets a shoutout!">

That works. I also want to put the value into the message_body text area.

<input type="text" name="message_subject" value=this.value" gets a shoutout!">

<input type="text" name="message_body" value=this.value" is cool">

How would I do that? I understand why it doesn't work, but not how to fix it.

Thanks

Fang
08-29-2003, 06:38 AM
<input type="text" size="50" Maxlength="50" value="" onblur="document.frmMain.message_body.value=this.value+' is cool';">

Each text input must have a different name!