I am trying to connect to a MySQL database using PHP, but I am getting 32767 error reporting in the console. I tried to show the error message using echo error_reporting()
but it is not showing the error message.
Here is the code:
$name = $_POST[name];
$topic = $_POST[topic];
$tell = $_POST[tell];
$birthDay = $_POST[birthDay];
$job = $_POST[job];
$email = $_POST[email];
$lastMajor = $_POST[lastMajor];
$major = $_POST[major];
$add = $_POST[add];
$today = "test";
$connectionString = mysqli_connect("localhost","root","root","myDB");
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
mysqli_query($connectionString,"INSERT INTO coWork (topic , name , tell , birthDay , job , email , lastMajor , major, add , date )
VALUES ('$topic', '$name','$tell','$birthDay','$job' , '$email' , '$lastMajor' , '$major' , '$add' , '$today')");
mysqli_close($connectionString);
echo error_reporting();
How can I get the content of the error message?