I run the following code, and no errors are shown; however, nothing after the $count.... works. I don't get an echo for count (the line echo "count =" . $count) 😕
I have the sample file up at http://register.pedalandplayinparadise.com/step1.php just, say "yes" and the user john doe exists.
Thank you in advance.
<?php
error_reporting(E_ALL);
ini_set('display_errors', True);
// ------------------------CONNECTION INFO
$dbc = mysqli_connect('', '', '', '');
if(!$dbc){echo "unable to connect"; echo $mysqli->connect_error;}
$firstName = $POST['first'];
$lastName = $POST['last'];
echo $firstName . " " . $lastName . "<br>";
$query = "SELECT * FROM 'riders' WHERE firstName=$firstName AND lastName=$lastName";
echo "query: " . $query . "<br>";
$result = mysqli_query($dbc, $query) or die (mysql_error());
if(!$result){echo mysql_error();}
if ($result){echo "Query completed successfully.";}
$count = mysql_num_rows($result) or die(mysql_error());
echo "count =" . $count;
$row = mysql_fetch_array($result)or die(mysql_error());
mysqli_close($dbc);
?>