Re: Search problems... :(

From: Date: Sun, 13 Jul 2003 16:35:28 +0000
Subject: Re: Search problems... :(
References: 1 2  Groups: php.db 
Request: Send a blank email to php-db+get-29217@lists.php.net to get a copy of this message
I have correct case sensitive error but it still don't work: RESULT CODE: $keys = explode (" ", $_POST ["chiave"]); $query = ""; foreach ($keys as $parola){ $parola = trim($parola); if ($parola != "") $query .= "titolo LIKE '%$parola%' OR testo LIKE '%$parola%' OR autore LIKE '%$parola%' OR "; } $query .= "0"; $query = "SELECT id, titolo, data FROM news WHERE " . $query; $result = mysql_query($query, $db); while ($row = mysql_fetch_array($result)) { echo "<a href=\"view.php?id=$row[id]\">" . date("j/n/y", $row[data]) . " - $row[titolo]</a><br>"; } Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in c:\programmi\apache group\apache\test\prova\result.php on line Any suggestion?

« previous php.db (#29217) next »