I get this error when trying to get this details page for a project to work. Its for school and I dont really understand PHP that well yet.
"You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1"
Here is the code for that page.
$recordID = $_GET['recordID'];
$query_Shoe_Details = "SELECT * FROM Products WHERE Shoe_Brand = $recordID";
$Shoe_Details = mysqli_query($conn, $query_Shoe_Details) or die(mysqli_error(($conn)));
$totalRows_Shoe_Details = mysqli_num_rows($Shoe_Details);
<title>details</title><?php include 'connection.php';?>
<p>Product Name: <?php echo $row_Shoe_Details['Product_Name']; ?></p>
<p>Description: <?php echo $row_Shoe_Details['Product_Description']; ?></p>
<p>Price: $<?php echo $row_Shoe_Details['Product_Price']; ?></p><?php
change your query as, use single quotes
$query_Shoe_Details = "SELECT * FROM Products WHERE Shoe_Brand = '$recordID'";
Also remove this
<?php include 'connection.php';?>, No need to include again