I'm extremely new to php so I don't doubt I'm just doing something stupid here.
Code:
The last statement in that is line 35.
Doesn't this:
Code:
make $stmt the correct type of object?
Code:
$mysqli = new mysqli($dbserver,$dbusername,$dbpassword);
if (mysqli_connect_errno()) {
printf("Connect failed: %s\n", mysqli_connect_error());
exit();
}
$stmt = $mysqli->prepare("SELECT * FROM ? WHERE user = ? AND pass = ?");
$stmt->bind_param('sss', $dbtable, $inputuser, $inputpass);
The last statement in that is line 35.
Quote:
Fatal error: Call to a member function bind_param() on a non-object in /home/students/rcgrube/public_html/oo.php on line 35
Doesn't this:
Code:
$stmt = $mysqli->prepare("SELECT * FROM ? WHERE user = ? AND pass = ?");
make $stmt the correct type of object?