tet3828 Posted October 24, 2006 Share Posted October 24, 2006 I must not have posed this question properly last post....22 reads to 1 response ::). Allow me to simplify...I have a database. Each Item in the database will have the following values:CATAGORYSUB-CATAGORYSTORE ITEM NUMBERNAMEDESCRIPTIONPRICWPRICE SMALL PICTUREPICTUREwhat script should I start with if I need all items in a selected catagory to be displayed in a table including an itme Name, Thumbnail, and price?Thanks again! ;D Link to comment https://forums.phpfreaks.com/topic/24932-file-description-thumbnail-and-full-size-image/ Share on other sites More sharing options...
Shad Posted October 24, 2006 Share Posted October 24, 2006 [code=php:0]<?phpif ($_GET['category']) { //this would be retrieved from e.g. index.php?category=something$category = $_GET['category'];//Lets say your table name is "products"$select = mysql_query("SELECT * FROM `products` WHERE `category`= '$category' ORDER BY `store_item_number` DESC");echo "<TABLE>";while ($qry = mysql_fetch_array($select)) {echo "<TR><TD>$qry[name]</TD><TD><IMG BORDER=\"0\" SRC=\"$qry[price_small_picture]\"></TD><TD>$qry[price]</TD></TR>";}echo "</TABLE>";}?>[/code]A very insecure and simple example. Link to comment https://forums.phpfreaks.com/topic/24932-file-description-thumbnail-and-full-size-image/#findComment-113642 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.