When i try the following structure, it does\'t send id=value
Specifying values in the action URI will have no effect, as the values in the URI will get overridden. To demonstrate, try the HTML and PHP code below. The form_test.html file could be renamed, but obviously, the PHP script needs to be named regurgitate.php (or the action in the form needs to be edited).
form_test.html:
Test of setting form action url
regurgitate.php:
Test PHP script for testing form action
\n";
foreach ($_GET as $k) {
echo "\$_GET['$k']: >" . $_GET["$k"] . "<
\n";
}
?>
When the submit button is clicked on form_test.html, the URL in my browser becomes something like:
http://www.example.com/regurgitate.php?Submit=Submit+Query&test=test
Note there's no "id=value" in the URL.
The output is:
In regurgitate.php
$_GET['Submit Query']: ><
$_GET['test']: >test<