Ver Mensaje Individual
  #8 (permalink)  
Antiguo 24/08/2007, 11:00
Avatar de GatorV
GatorV
$this->role('moderador');
 
Fecha de Ingreso: mayo-2006
Ubicación: /home/ams/
Mensajes: 38.567
Antigüedad: 18 años
Puntos: 2135
Re: buscador avanzado

Prueba asi:
Código PHP:
<?php $query "SELECT * FROM noticias WHERE titulo LIKE '%$campo1%' AND contenido LIKE '%$campo2%'"
$ssql mysql_query($query$link); 
if(
mysql_num_rows$ssql ) == 0) {
 echo 
"No existen resultados"
} else  {
while(
$tabla=mysql_fetch_array($ssql)) {
 echo 
"<table width='655' border='1' cellspacing='0' cellpadding='0'>";
 echo 
"<tr><td><strong>Noticia: </strong>".$tabla['titulo']."</td></tr>";
 echo 
"</table>";
 echo
"<br>";
}
}
?>
Saludos.