|
Posted by Erwin Moller on 02/21/07 09:57
mosesdinakaran@gmail.com wrote:
> Hi All,
>
> I need a small clarification in submitting the forms, Ur
> suggestions please.
>
> In a page I have two form and also two submit butons.
>
>
> (ie)
>
> <form name="myform" action="test.php" method="post" >
> <input type="text" name="myform_name" >
> <input type="text" name="myform_id" >
> <input type="text" name="myform_no" >
> <input type="submit" value="Submit" />
> </form>
>
> <form name="myform1" action="test.php" >
> <input type="text" name="myform1_name" >
> <input type="text" name="myform1_id" >
> <input type="text" name="myform1_no" >
> <input type="submit" value="Submit" />
> </form>
>
> Now is it possible to submit all the elements from the two form when I
> click any one of the submit button.
>
>
>
> Thanks & Regards
> Moses
Hi,
Yes, but not with PHP.
PHP has NO KNOWLEDGE what is going on in the browser. It only sends the
html/javascript/images/whatever the browser displays.
So try Javascript, that language lives in a browser.
Note however that some people choose to have Javascript disabled in their
browser.
If you go Javascript, just add a bunch of hidden fields in both forms, and
fill them before submitting with the values from the other form.
If you need more help: comp.lang.javascript, an active group.
Regards,
Erwin Moller
Navigation:
[Reply to this message]
|