basic filtering PHP...
i have a product page showing all products. this is linked to the product-detail page and working fine
<div id="indexImage"><a href="SS13product-description.php?ID=<?php echo $row_Recordset1['ProductID']; ?>"><img src="../images/SS13/thumbs/<?php echo $row_Recordset1['ImageDetail']; ?>"/></a></div>
on the description page i have the following SQL
$var1_rsProduct = "-1";
if (isset($_GET['ID'])) {
$var1_rsProduct = $_GET['ID'];
}
mysql_select_db($database_beau, $beau);
$query_rsProduct = sprintf("SELECT * FROM beauSS13_Cat, beauSS13_products, beauSS13_Stock, beauSS13_SizeList WHERE beauSS13_products.CatID = beauSS13_Cat.catID AND beauSS13_products.ProductID = beauSS13_Stock.ID AND beauSS13_Stock.SizeID = beauSS13_SizeList.SizeID AND beauSS13_products.ProductID = %s", GetSQLValueString($var1_rsProduct, "int"));
$rsProduct = mysql_query($query_rsProduct, $beau) or die(mysql_error());
$row_rsProduct = mysql_fetch_assoc($rsProduct);
$totalRows_rsProduct = mysql_num_rows($rsProduct);
what i want to do on this product description page aswell is show all the products from that category
i made the following but this just shows the same product and not all the other products
mysql_select_db($database_beau, $beau);
$query_rsCategory = "SELECT * FROM beauSS13_Cat, beauSS13_products WHERE beauSS13_products.CatID = beauSS13_Cat.catID";
$rsCategory = mysql_query($query_rsCategory, $beau) or die(mysql_error());
$row_rsCategory = mysql_fetch_assoc($rsCategory);
$totalRows_rsCategory = mysql_num_rows($rsCategory);
where am i gonig wrong?
