Date Recieved field? yup it has it: $Date_Received = date('Y-m-d',strtotime($_POST['Date_Received'])); $query= "INSERT INTO ncmrtest ('$Date_Received')"; values('$Date_Received')"; PHP: Thanks about the PO though.
Bloody hell, that PO bit was it... that little thing, it wasn't even erroring on the right part... You know you've been working on something way too long when you don't see something like that right in front of you... Thanks for the help.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>PDI Non-Conforming Materials Report </title> </head> <body> <h2>PDI Non-Conforming Materials Report</h2> <?php $Added_By = $_POST['Added_By']; $Added_By_Date = date('Y-m-d',strtotime($_POST['Added_By_Date'])); $Nexx_Part = $_POST['Nexx_Part']; $Nexx_Rev = $_POST['Nexx_Rev']; $Nexx_Part_Description = $_POST['Nexx_Part_Description']; $NCMR_Qty = $_POST['NCMR_Qty']; $JO = $_POST['JO']; $SN = $_POST['SN']; $INV = $_POST['INV']; $Nexx_Inventory_On_Hand = $_POST['Nexx_Inventory_On_Hand']; $Nexx_Inventory_Chk = $_POST['Nexx_Inventory_Chk']; $Supplier_Name = $_POST['Supplier_Name']; $Supplier_Number = $_POST['Supplier_Number']; $Manufacturer_Part_Number = $_POST['Manufacturer_Part_Number']; $Manufacturer_Serial_Number = $_POST['Manufacturer_Serial_Number']; $NCMR_ID = $_POST['NCMR_ID']; $Nonconformity = $_POST['Nonconformity']; $Disposition = $_POST['Disposition']; $Comments = $_POST['Comments']; $CommentsAdditional_Details = $_POST['CommentsAdditional_Details']; $PO = $_POST['PO']; $PO_Date = date('Y-m-d',strtotime($_POST['PO_Date'])); $Date_Received = date('Y-m-d',strtotime($_POST['Date_Received'])); $dbc = mysqli_connect('localhost', 'pawz_PDI', 'xxxxxx', 'pawz_PDI') or die('Error connecting to MySQL server.'); $query= "INSERT INTO ncmrtest (Added_By, Added_By_Date, Nexx_Part, Nexx_Rev, Nexx_Part_Description, NCMR_Qty, JO, SN, INV, Nexx_Inventory_On_Hand, Nexx_Inventory_Chk, Supplier_Name, Supplier_Number, Manufacturer_Part_Number, Manufacturer_Serial_Number, NCMR_ID, Nonconformity, Disposition, Comments, CommentsAdditional_Details, PO, PO_Date, Date_Received) values('$Added_By', '$Added_By_Date', '$Nexx_Part', '$Nexx_Rev', '$Nexx_Part_Description', '$NCMR_Qty', '$JO', '$SN', '$INV', '$Nexx_Inventory_On_Hand', '$Nexx_Inventory_Chk', '$Supplier_Name', '$Supplier_Number', '$Manufacturer_Part_Number', '$Manufacturer_Serial_Number', '$NCMR_ID', '$Nonconformity', '$Disposition', '$Comments', '$CommentsAdditional_Details', '$PO', '$PO_Date', '$Date_Received')"; if (!$result = mysqli_query($dbc, $query)) { printf("Error message: %s\n", mysqli_error($dbc)); } mysqli_close($dbc); echo 'Thanks for submitting the form. The information has been entered and will be reviewed by the correct personnel.<br />'; ?> </body> </html> Code (markup):
This is the code for output.php correct? There are no syntax errors. Are you sure you have mysqli installed?
What is line 50 in your code? I'm copying and pasting into my own editor but line 50 is blank so there might be a difference in the line breaks. Post your line 50.