I have the tables in the database well done, but then when I do the code, the content does not even appear, I wanted to have help sff'
The code I have is this:
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 1 ORDER BY id_menu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo "<li> ".$linha[''] . " " . $home ." </li>";
}
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 2 ORDER BY id_menu ") or die(mysql_error());
$result = mysql_query("SELECT titulo FROM submenu WHERE id_submenu = 2 ORDER BY id_submenu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo " <li class= 'dropdown ' >
<a echo $orgaosMenu; href='#' class='dropdown-toggle' data-toggle='dropdown' style='padding-top: 15px;border-top: 0px solid #3B7D26;'>" . $linha['titulo'] . "<b class='caret'></b></a>
" . $orgaosMenu . "</li>";
while($line = mysql_fetch_array($result)){
echo "<ul class='dropdown-menu'>
<li> " .$line['titulo'] . " </li>";
}
}
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 3 ORDER BY id_menu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo " <li class= 'dropdown ' >
<a echo $autarcasMenu; href='#' class='dropdown-toggle' data-toggle='dropdown' style='padding-top: 15px;border-top: 0px solid #3B7D26;'>" . $linha['titulo'] . "<b class='caret'></b></a>
" . $autarcasMenu . "</li>";
}
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 4 ORDER BY id_menu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo " <li class= 'dropdown ' >
<a echo $militanciaMenu; href='#' class='dropdown-toggle' data-toggle='dropdown' style='padding-top: 15px;border-top: 0px solid #3B7D26;'>" . $linha['titulo'] . "<b class='caret'></b></a>
" . $militanciaMenu . "</li>";
}
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 5 ORDER BY id_menu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo " <li >
<a echo $multimediaMenu; href='#' class='dropdown-toggle' data-toggle='dropdown' style='padding-top: 15px;border-top: 0px solid #3B7D26;'>" . $linha['titulo'] . "<b ></b></a>
" . $multimediaMenu . "</li>";
}
$resultado = mysql_query("SELECT titulo FROM menu WHERE id_menu = 6 ORDER BY id_menu ") or die(mysql_error());
while($linha = mysql_fetch_array($resultado)) {
echo " <li >
<a echo $contactosMenu; href='http://www.w3schools.com/php/php_mysql_where.asp' class='dropdown-toggle' data-toggle='dropdown' style='padding-top: 15px;border-top: 0px solid #3B7D26;'>" . $linha['titulo'] . "<b ></b></a>
" . $contactosMenu . "</li>";
}
?>