I am currently attempting to run a piece of code via php which will create a table in which values can be inputted into the table and updated via an ajax call. This latter part is not the problem.
However, despite a similar style of program working in the document, the submit button doesn't actually do anything at all. I attempted to add a hidden field to the button, but nothing registered. Below is the code on the pages:
Original button, linked on an include and posting to the main page:
<form action="main.php" method="post">
<input type="hidden" name="hidden" value="13timesasecond"/>
<input type="button" id="clicky" value="Create" name="create"/>
</form>
main homepage, for validations' sake.
if (isset($_POST['hidden'])) {
include_once $includepath."module.inc.php";
echo $_POST['hidden'];
}
else {
echo "The button broke :(";
}
The actual module:
echo "<div class=dataset>
<p><u>New Dataset</u></p>
<form>
<input type=radio name=rating value=red> Red
<input type=radio name=rating value=amber> Amber
<input type=radio name=rating value=green> Green
</form>
<table border=1 align=left>
<tr>
<td>Field 1</td>
<td>Field 2</td>
<td>Field 3</td>
<td>Field 4</td>
</tr>
<tr>
<td><input type=text/></td>
<td><input type=text/></td>
<td><input type=text/></td>
<td><input type=text/></td>
</tr>
</table>
</div>";
The other stuff is currently not done, and the issue is with the button not actually causing anything to echo on click despite other pages using almost exactly the same thing in the website.