In article <25d4a987.0310161218.42aa98fb (AT) posting (DOT) google.com>,
webjunk4me (AT) hotmail (DOT) com enlightened us with...
Quote:
Hi There,
The following is a popup form that works exactly as I want but I now
need to get the values of each text box added when a user clicks the
'Add' button and pass the values back the opener form into a textarea.
Thanks in advance! |
Substitute your form names in the code. Assumes you want the values of
ALL text elements in the form.
var s="";
var l = document.formName.elements.length; //popup form name here
for (var i=0; i<l; i++)
{
e = document.formName.elements[i]; //popup form name here
if (e.type=="text") s+= e.value+" "; // space between values so
one can read them
}
opener.document.formName.elementName.value = s; //opener form name and
the textarea name here
-------------------------------------------------
~kaeli~
Jesus saves, Allah protects, and Cthulhu
thinks you'd make a nice sandwich.
http://www.ipwebdesign.net/wildAtHeart http://www.ipwebdesign.net/kaelisSpace
-------------------------------------------------