Ver Mensaje Individual
  #2 (permalink)  
Antiguo 09/09/2011, 07:13
Avatar de Patriarka
Patriarka
 
Fecha de Ingreso: enero-2011
Ubicación: Moreno, Buenos Aires, Argentina
Mensajes: 2.851
Antigüedad: 13 años, 3 meses
Puntos: 288
Respuesta: Cómo hacer link a esto??

De la forma Clasica:
Código PHP:
Ver original
  1. <?php
  2.    include("conexion.php");
  3.  
  4.    $link=Conectarse();
  5.    $consulta="SELECT * FROM tblnewsarticles limit 1";
  6.    $resultado = mysql_query($consulta, $link);
  7. while ($row = mysql_fetch_array($resultado)){
  8. ?>
  9. <h2 style='color:#be0000'>
  10. <a href="detalle.php?id_articulo=<?php echo $row['articleID']; ?>">
  11. <?php echo $row['article_title']
  12. </a>
  13. </h2>
  14.  
  15. <?php
  16. }
  17. ?>
  18.  
  19. detalle.php
  20.  
  21. <?php
  22. $id_articulo = isset($_GET['id_articulo'])?$_GET['id_articulo']:0;
  23.  
  24.  
  25. include("conexion.php");
  26.  
  27.    $link=Conectarse();
  28.    $consulta="SELECT * FROM tblnewsarticles where articleID=".$id_articulo;
  29.    $resultado = mysql_query($consulta, $link);
  30.    $row = mysql_fetch_array($resultado);
  31.    echo $row['article_html'];
  32. ?>