I'm having a problem with a snippet of my code not entering data into the database. Does anyone see it? Cuz, I don't see it...
I'm using 000's free web hosting for testing purposes if that matters.
$ConnServ is included via another
.PHP page and is working on multiple other requests to server. All spelling has been checked multiple times. This script worked at one point but it was a separate page. It was then consolidated onto the same page as the HTML form for 'required field' checking.
Code is throwing zero errors.
<form action="<?php $_SERVER['PHP_SELF']; ?>" method="post" accept-charset="utf-8" enctype="multipart/form-data"> <!-- this was included to show how the form interacts with the below code. -->
//Add Table Data $sql = $ConnServ->prepare("INSERT INTO TestingDatabase (file,fileTwo,text,textTwo,tPos,tPosTwo,owner,createDate,invisible,tags) VALUES (?,?,?,?,?,?,?,?,?,?)"); $sql->bind_param("ssssiissis",$fileName,$fileName2,$textinput,$textinput2,$textPos,$textPos2,$ContentOwner,$currentDate,$visState,$lineTags); $sql->execute(); $sql->close(); //echo '<a>'. $fileName . $fileName2 . $textinput . $textinput2 . $textPos . $textPos2 . $ContentOwner . $currentDate . $visState . $lineTags .'</a>'; //<- this will echo the correct data from the form inputs if not commented out.
No data is being input into the database fields, the auto increment is not being incremented either, yet all the data seems to make it to the
If it's something simple I'm going to bed...