Click to See Complete Forum and Search --> : Form submition


AluminX
01-10-2008, 11:29 PM
couple of questions. i searched about this and couldn't find anything untill i got bored.
1) i know firefox has an issue on sending form inputs by id, i.e.
<input type="text" id="myField" />
ff won't submit myField however if i add name attrb
<input type="text" id="myField" name="myField" />
why does it do that?

2) is it possible to submit a form (<form action="someserver.php" method="get"></form>) and remaining on the same page without using ajax calls?(i guess if the form is embeded into php?)

Articles about these questions would be greatly appreciated.

Thanks in advance.

hex1a4
01-11-2008, 05:24 PM
2) is it possible to submit a form (<form action="someserver.php" method="get"></form>) and remaining on the same page without using ajax calls?(i guess if the form is embeded into php?)

Articles about these questions would be greatly appreciated.

Thanks in advance.

Yes. Simply set ACTION to the same page. For example:
If the form is on mypage.php you can set action="mypage.php"

roscor
01-11-2008, 07:50 PM
or<form name="yourformname" action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" > which on submission of your form will parse itself and return the result which you have set via your code, be that validation, logon, etc