html select, and inserting to var. ?!
Hi all again !
now i just wanna know this, i have html select which will sort the sub_cat, sub_cat_id, and catagory :
with this way i can insert just the sub_cat, i need to insert the catagory also into another table which include catagory and sub_cat field ?
$sql_cat="select * from subcat";
echo "<select name=\"newsub_cat\">";
echo"<option value=\"$sub_cat\">:: $catagory ::: $sub_cat ::: $sub_cat_id ::</option>";
i was trying with this :
but didn`t work !
$query = mysql_query("Select catagory from subcat where newsub_cat='$sub_cat'",$db);
list($sub_cat_id, $sub_cat, $catagory) = mysql_fetch_row($query);
echo "[$catagory] $newsub_cat";