Hi! My links have 18 main categories and 600 somethings subcategories and i want to build a drop down menu for a powersearch option. Below is the script
$result2 = mysql_query("SELECT cid,title FROM yp_cat ORDER BY title");
echo "<select name=\"cid\">";
echo"<option value=\"ANY\">[ ANY ]</option>";
while(list($cid, $title) = mysql_fetch_row($result2)) {
echo "<option value=\"$cid\">$title</option>";
}
$cid - stand for categories id
this script retrieve all the main categories and subcategories in the mysql database. I want to select only the first 18 categories from the database from rows 1-18 and not everything. Please help me out.....
Thanks ahead....
Mike