"sindre" <si******@c2i.net> wrote in message
news:4G********************@news000.worldonline.dk ...
Hi,
I have a form with many fields. And then I thought I could have two other
forms similar but here is only the submit button visible.
What I want is: if the user click on a submit button on a hidden form the
information typed into the visible form is copied two the not
visible form and submitted.
This way I can submit the visible form to three pages depending on the
form submitted.
Is this possible?
Regards,
Sindre
Perhaps a variation of the following?
<html>
<head>
<title>forms.htm</title>
<script type="text/javascript">
function submits() {
var form1 = document.form1;
var form2 = document.form2;
var form3 = document.form3;
form1.Field2.value = form2.Field2.value;
form1.Field3.value = form3.Field3.value;
return true;
}
</script>
</head>
<body>
<form name="form1" onsubmit="return submits()">
<input type="text" name="Field1" value="1">
<input type="hidden" name="Field2" value="1">
<input type="hidden" name="Field3" value="1">
<br><input type="submit" value="Submit Form">
</form>
<form name="form2">
<input type="hidden" name="Field2" value="2">
</form>
<form name="form3">
<input type="hidden" name="Field3" value="3">
</form>
</body>
</html>