Ver Mensaje Individual
  #17 (permalink)  
Antiguo 22/07/2011, 15:56
Avatar de DinamiteDog
DinamiteDog
 
Fecha de Ingreso: febrero-2005
Ubicación: Rosario, Argentina
Mensajes: 77
Antigüedad: 19 años, 2 meses
Puntos: 4
Respuesta: no jme escribe en la BD

Entonces sería...

Código PHP:
Ver original
  1. <?php
  2. $connect=mysql_connect("xxx","xxx","xx");
  3. mysql_select_db("db375118189",$connect);
  4. $titulo=$_POST['titulo'];
  5. $autor=$_POST['autor'];
  6. $categoria=$_POST['categoria'];
  7. $articulo=$_POST['articulo'];
  8. $sql = "INSERT INTO noticias VALUES(NULL, '$autor', '$titulo', '$categoria', NOW(), '$articulo')";
  9.  
  10. mysql_query($sql, $connect) or die("Tuve un error en: " . mysql_error() . "<br />Con la consulta: " . $sql);
  11.  
  12. ?>
__________________
All generalizations are false, including this one ~ Mark Twain