bom, tae o script ki eu to tentando arrumar:
esse eh o modelo de como eu quero o menu...
<table width="113" border="0" cellpadding="0" cellspacing="0"> <tr valign="top" align="center"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000"> <font color="#FF8000" face="Comic Sans MS" size="2">:: Cat 01 ::</font></td></tr> <? $select = mysql_query("select * from drop_menu01 ORDER BY id ASC"); // executando SQL if (mysql_num_rows($select) > 0) { // se existir resultado while ($show = mysql_fetch_array($select)) { // mostra ?> <tr valign="top"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000" onmouseover="ativo(this);" onmouseout="inativo(this);" onclick="clicado(this);"><a href="#" style="text-decoration:none" onClick="location='<?=$show[url]?>'"> <font color="#000000" face="Comic Sans MS" size="2">|-<?=$show[menu]?></font></a></td></tr><? } } ?> <tr valign="top" align="center"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000"><font color="#FF8000" face="Comic Sans MS" size="2"> :: Cat 02 ::</font></td></tr> <? $select = mysql_query("select * from drop_menu02 ORDER BY id ASC"); // executando SQL if (mysql_num_rows($select) > 0) { // se existir resultado while ($show = mysql_fetch_array($select)) { // mostra ?> <tr valign="top"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000" onmouseover="ativo(this);" onmouseout="inativo(this);" onclick="clicado(this);"><a href="#" style="text-decoration:none" onClick="location='<?=$show[url]?>'"> <font color="#000000" face="Comic Sans MS" size="2">|-<?=$show[menu]?></font></a></td></tr><? } } ?> <tr valign="top" align="center"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000"><font color="#FF8000" face="Comic Sans MS" size="2"> :: Cat 03 ::</font></td></tr> <? $select = mysql_query("select * from drop_menu03 ORDER BY id ASC"); // executando SQL if (mysql_num_rows($select) > 0) { // se existir resultado while ($show = mysql_fetch_array($select)) { // mostra ?> <tr valign="top"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000" onmouseover="ativo(this);" onmouseout="inativo(this);" onclick="clicado(this);"><a href="#" style="text-decoration:none" onClick="location='<?=$show[url]?>'"> <font color="#000000" face="Comic Sans MS" size="2">|-<?=$show[menu]?></font></a></td></tr><? } } ?> </table>ele estah fazendo 3 selecoes sql, prq sao 3 categorias... mas eu queria arrumar isso...
dai to tentando assim...:
<table width="113" border="0" cellpadding="0" cellspacing="0"> <? $select = mysql_query("select * from cat_menu order by cat_id ASC"); // executando SQL // $select = mysql_query("select * from cat_menu, drop_menu where cat_menu.cat_id = drop_menu.cat_id order by cat_menu.cat_id ASC") if (mysql_num_rows($select) > 0) { // se existir resultado while ($show = mysql_fetch_array($select)) { // mostra ?> <tr valign="top" align="center"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000"><font color="#FF8000" face="Comic Sans MS" size="2"> <?=$show[cat_menu]?></font></a></td></tr><? ?> <? $select2 = mysql_query("select * from drop_menu order by menu_id ASC"); // executando SQL if (mysql_num_rows($select2) > 0) { // se existir resultado while ($show = mysql_fetch_array($select2)) { // mostra ?> <tr valign="top"><td width="114" style="border-top:1px solid #000000; border-bottom:1px solid #000000" onmouseover="ativo(this);" onmouseout="inativo(this);" onclick="clicado(this);"><a href="#" style="text-decoration:none" onClick="location='<?=$show[url]?>'"> <font color="#000000" face="Comic Sans MS" size="2">|-<?=$show[menu]?></font></a></td></tr><? }}}} ?> </table>
tem umas linhas ae que estao comentadas... foi uma das milhares de tentativas ki eu fiz pra ver se dava jeito!!! mas nao deu...
alguem me dah um help?!
valeusssssssssss!