|
-- Posted by Eric 2009 at 2:47 pm on Aug. 30, 2007
this is my code $cat = $_POST['cat']; $type = $_POST['type']; $query = mysql_query("SELECT '$cat' FROM 'band' WHERE ' . $cat . '= ' . $type . '"); $query_row=mysql_fetch_array($query); echo($query_row['$type']); echo $result; i have a drop down menu that indeicates which table the user wants to search, $cat, and their specification in a text,$type. I just doesnt work i have gotten about 20 differnt results, sometimes it wont return anything, others i will get a resource id#3, and sometiems a syntax error, whenever i change it, if someone would help me please!
|