So I am stumped, I am getting:
Fatal error: Call to a member function bind_param() on a non-object in 'Website Address' on line 261
- I have other queries of the exact same nature on other pages, and they work.
- I have closed out all previous queries
- I have checked spelling, punctuation of all tables/columns in the SQL database.
- The $conn variable is the databse connection, and it works in other queries.
I feel like it is something simple, but I am just not seeing it.
Code:
$Key = $_GET["Key"];
$Select_Groups_Query = "
SELECT Group_Name,
Group_Key,
Group_Members_User_Key,
Group_Members_Group_Key
FROM Group_Members
INNER JOIN Group ON Group_Members_Group_Key = Group_Key
WHERE Group_Members_User_Key = ?
";
$Select_Groups_stmt = $conn->prepare($Select_Groups_Query);
$Select_Groups_stmt->bind_param('s', $Key);
$Select_Groups_stmt->execute();
$Select_Groups_stmt->bind_result($Group_Name, $Group_Key, $Group_Members_User_Key, $Group_Members_Group_Key);