<?php include './conexion.php'; include './DAOAdministracion/DAOUsuarios.php'; $cn = new conexion(); $dao = new DAOUsuarios(); $cn->conectarse(); $rs = $dao->dameUsuarios(); if ($rs == false) { echo mysql_error(); } else { if (mysql_affected_rows() > 0) { ?> <table class="table"> <thead> <th>Nombre</th> <th>Apellidos</th> <th>Correo</th> <th>Telefono</th> </thead> <tr> <?php while ($rsDatosUsuario = mysql_fetch_array($rs)) { ?> <td><?php echo $rsDatosUsuario["nombre"]; ?> </td> <td><?php echo $rsDatosUsuario["apellidoPaterno"] . " " . $rsDatosUsuario["apellidoMaterno"]; ?>
<?php include './DAOAdministracion/DAOProductos.php'; include './DAOAdministracion/DAOUsuarios.php'; include './conexion.php'; $dao = new DAOProductos(); $daoUsuarios = new DAOUsuarios(); $cn = new conexion(); $cn->conectarse(); $rs = $dao->dameProductos(); $rsUsuarios = $daoUsuarios->dameUsuarios(); echo '<div><h1>Módulo de productos</h1><div>'; if ($rsUsuarios == false) { echo '<table class ="table"><tr><td>' . mysql_error() . '</td></tr></table>'; } else { echo '<select onchange="dameProductosUsuario();" id="cmbUsuarios">'; echo '<option>Seleccione un Usuario</option>'; while ($datosUsuario = mysql_fetch_array($rsUsuarios)) { echo '<option value ="' . $datosUsuario["idUsuario"] . '">' . $datosUsuario["nombre"] . '</option>'; } echo '</select>'; } echo '<br>'; echo '<br>'; if ($rs == true) { echo '<table class="table">'; echo '<thead> <th><center>Nombre</center></th> <th><center>Descripcion</center></th> <th><center>Precio</center></th> <th><center>Fecha Prublicacion</center></th>