PHP Error

From: Date: Mon, 20 Aug 2001 11:07:48 +0000
Subject: PHP Error
Groups: php.db 
Request: Send a blank email to php-db+get-11542@lists.php.net to get a copy of this message
I'm using this script for connect to a mysql database but it only works in php3 not in php4, any ideas? $servidor = "localhost"; $usuario = "user"; $clave = "pass"; $base = "database"; $id = mysql_connect($servidor,$usuario,$clave); $conexion = mysql_select_db($base, $id); $consulta = "SELECT * FROM Recursos"; $res = mysql_query($consulta,$conexion); $numero = mysql_num_rows($res); return $numero; In php3 returns the number of fields, but in php4 get the followings errors Warning: Supplied argument is not a valid MySQL-Link resource Warning: Supplied argument is not a valid MySQL result resource

« previous php.db (#11542) next »