I have a form that has various inputs. One of the inputs contains a pre determined value that is loaded by script that is named "invoiceid". This invoiceid is the name and id of the form input and also the name of a column in my database. How can update the row in my database that contains the same value under the invoiceid column with all other form data submitted? I dont know what I'm doing...please help. Thanks for your time.
FORM
<form action="update.php" id="contactForm" method="post">
<input id="invoiceid" name="invoiceid" type="hidden" value=""/>
<input id="txt1" name="txt1" type="text" value=""/>
<input id="q1" name="q1" value="9.50" checked="checked" type="radio">
<input id="q1" name="q1" value="12.50" type="radio">
<select id="selectbox" name="selectbox">
<option selected="selected" value="">Please select...</option>
<option value="PURCHASE">Order for Purchase</option>
<option value="REVIEW">Order for Review</option>
</select>
<button id="btn1" type="submit" name="submit">Submit</button></div>
</form>
update.php
//Table name: seguin_orders
<?php
// Create the connection to the database
$con=mysqli_connect("xxx","xxx","xxx","xxx");
// Check if the connection failed
if (mysqli_connect_errno()) {
echo "Failed to connect to MySQL: " . mysqli_connect_error();
die();
}
if (isset($_GET['invoiceid']))
{
$invoiceid= $_GET['invoiceid'];
}
?>