blueman378 Posted June 4, 2008 Share Posted June 4, 2008 hi guys, im trying to do something, i only need the last result, so should this work? $query = mysql_query("SELECT * FROM sub_categories WHERE id='$products[cid]'") or die(mysql_error()); $result = mysql_query($query); $row = mysql_fetch_assoc($result); $subcat = $row[Name]; $query = mysql_query("SELECT * FROM main_categories WHERE id='$row[mid]'") or die(mysql_error()); $result = mysql_query($query); $row = mysql_fetch_assoc($result); $maincat = $row[Name]; echo"<td valign=\"top\">$maincat >> $subcat</td> obviously thats a snippet, i dont get any error or anything, jsut those values dont get filled Link to comment https://forums.phpfreaks.com/topic/108679-solved-should-this-work/ Share on other sites More sharing options...
blueman378 Posted June 4, 2008 Author Share Posted June 4, 2008 never mind mixing codes late at night = stupid mistakes Link to comment https://forums.phpfreaks.com/topic/108679-solved-should-this-work/#findComment-557294 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.