aui les dejo el codigo
Código PHP :
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Documento sin título</title> <link href="estilo.css" rel="stylesheet" type="text/css" /> <script language="javascript" src="stuHover.js"></script> </head> <body> <table width="826" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <th colspan="2" class="encabezado" scope="col"> </th> </tr> <tr> <td valign="top" class="fondo_menu"> <div><img src="images/dcr_04.jpg" width="195" height="178" border="0px" /></div> <div class="menu_arriba"></div> <ul id="nav"> <?php include("conec.php"); $sql="SELECT * FROM menus where publicar=1 ORDER BY orden"; $consulta=mysql_query($sql,$link); while ($menu=mysql_fetch_array($consulta)){ ?> <li> <a href="#"> <?php echo $menu[2]; ?></a> <ul><?php $id_menu=$menu[0]; $sql_1="select * from articulos where id_menu='$id_menu' and publicar=1 order by orden"; $consulta_1=mysql_query($sql_1,$link); while ($articulo=mysql_fetch_array($consulta_1)){ $id_articulo=$articulo[0]; $contenido=$articulo[5]; ?> <li><a <?php echo "href='index.php?articulo=$id_articulo'"?>> <?php echo $articulo[2]; ?> </a></li><?php } mysql_free_result($consulta_1); ?></ul> </li> <?php } mysql_free_result($consulta); ?> </ul> <div class="pie_menu"></div> </td> <td rowspan="2" valign="top" class="fondo_cont"> <div class="part01_2"></div> <div class="contenido"> <?php include("conec.php"); if ($_GET){ $articulo=$_GET["articulo"]; $sql_2="select titulo_articulo,contenido from articulos where id_articulo=$articulo"; $consulta_2=mysql_query($sql_2,$link); while ($contenido=mysql_fetch_array($consulta_2)){ $titulo=$contenido[0]; echo "<h3>".$titulo."</h3>"; $texto=$contenido[1]; echo $texto; } mysql_free_result($consulta_2); mysql_close($link); } else { echo "<script>window.location.href('index.php?articulo=41')</script>";-------> no Funciona } ?> </div> </td> </tr> <tr> <td valign="top" class="fondo_menu"> </td> </tr> <tr> <td class="menu_inf01"></td> <td class="menu_inf02"></td> </tr> <tr> <td colspan="2" align="center" valign="middle" bgcolor="#FFFFFF">bla blabla jejejejje</td> </tr> </table> </body> </html>