PDA

View Full Version : Extracting values of form-elements


scriptpeter
09-26-2000, 09:15 AM
I have set up a form within a <div>-block, like this:

<div id="mydiv" style="position:absolute">
<frm name="myform">
<input="text" name="mytext">
</frm>
</div>

How can I extract the value of the element "mytext" with Netscape 4x using JavaScript?

Thanks!

Peter

Ian
09-26-2000, 09:32 AM
Hi Peter,
You will have to do several things, first you need to give your form an action (function) and a method (what you want to do with the info "mytext"), then you have to write a function. If you want to email the info that has been inputed, check out the source of some of the email form scripts on A1 JavaScripts (http://www.a1javascripts.com/essential_scripts/ ) to get some ideas.
I hope this helps.


------------------
Ian

Web Development - BIG Resources Inc
Head Guide - 123Webmaster.com (http://www.123webmaster.com/)
ian@123webmaster.com
BIG Resources.com (http://www.bigresources.com)
ICQ: 25828668