PHP: $name = $this->getName(); $rank = "Player"; $start = 200; $i = 0; $data = $db->prepare("INSERT INTO playerdata(username, rank, money, kills, deaths, pvpenabled, pvptime) VALUES (?, ?, ?, ?, ?, ?, ?)"); $data->bind_param("ssiiiii", $name, $rank, $start, $i, $i, $i, $i); $data->execute(); $data->close(); I'm trying to insert data into my table but it isn't inserting. 1. There is no error when the server calls the code it just doesn't insert data in the database 2. Yes, the database is connected to the server (Tested the connection before)
var_dump($data->error); will show you the error. Alternatively, you can configure mysqli_report() to throw errors. PHP: mysqli_report(MYSQLI_REPORT_ALL & ~MYSQLI_REPORT_INDEX); // call right before creating mysqli instance$data = new mysqli(...);
I did that and this is what i'm getting Code: string(0) "" Actually it did update into mysql but for some reason (playername).dat isnt saving[/CODE]