Ver Mensaje Individual
  #1 (permalink)  
Antiguo 06/03/2016, 06:30
santi2892009
 
Fecha de Ingreso: mayo-2012
Mensajes: 363
Antigüedad: 12 años
Puntos: 0
no consigo imprimir el nombre del usuario por pantalla

buenas tardes a ver si me pueden ayudar con el codigo y si pueden decirme en que falla:
Código PHP:
Ver original
  1. <?php
  2.  
  3.     session_start();
  4. require_once('../../../../../../Connections/conexiondatos.php');
  5.  
  6.  
  7. $ident = mysql_real_escape_string($_GET['id']);
  8.      $perfil = mysql_query("SELECT * FROM ex_usuarios WHERE id='".$ident."'") or die(mysql_error());
  9.     if(mysql_num_rows($perfil)) { // Comprobamos que exista el registro con la ID ingresada
  10.         $row = mysql_fetch_array($perfil);
  11.         $id = $row["id"];
  12.         $usuario = $row["usuario"];
  13.         $email = $row["email"];
  14.         $freg = $row["freg"];
  15. ?>
  16. <style type="text/css">
  17. .estilo {
  18.     background-color: #FC6;
  19. }
  20. .fondo {
  21.     background-color: #999;
  22. }
  23. </style>
  24. </head>
  25.  
  26. <body>
  27. <br/>
  28. <table width="634" height="201" border="1" cellspacing="3">
  29.   <tr class="fondo">
  30.     <th width="307" height="193" scope="col"><div align="center">
  31.       <table width="248" border="1" cellspacing="3">
  32.         <tr>
  33.           <th class="estilo" scope="col"><?=$usuario?></th>
  34.           </tr>
  35.       </table>
  36.       <p>&nbsp;</p>
  37.     </div></th>
  38.     <th width="308" height="193" scope="col"><div align="center">
  39.         <table width="200" border="1" cellspacing="3" class="estilo">
  40.           <tr>
  41.             <th scope="col"><div align="left">fecha de ingreso:</div></th>
  42.           </tr>
  43.           <tr>
  44.             <td>&nbsp;</td>
  45.           </tr>
  46.           <tr>
  47.             <td><div align="left"></div></td>
  48.           </tr>
  49.           <tr>
  50.             <td><div align="left"></div></td>
  51.           </tr>
  52.         </table>
  53.     </div></th>
  54.   </tr>
  55. </table>
  56. </body>
  57. </html>
  58. <?php
  59.     }else {
  60. ?>
  61.         <p>El perfil seleccionado no existe o ha sido eliminado.</p>
  62. <?php
  63.     }
  64. ?>  
  65. // ------------------------------------------------------------------------

el cual donde quiero imprimir el nombre del usuario no sale nada