Ver Mensaje Individual
  #1 (permalink)  
Antiguo 31/05/2011, 16:43
ikeyman
 
Fecha de Ingreso: febrero-2010
Mensajes: 56
Antigüedad: 14 años, 2 meses
Puntos: 1
Exclamación Error en funcion

Buenas, tengo la siguiente función:
Código PHP:
function check_game($game) {
global 
$link;
$sql        =  "SELECT * FROM games WHERE name='$game'";
$rs         =   mysql_query($sql$link);
$row        =   mysql_fetch_array($rs);
if(
$row['id'] == ''){ 
return 
false;
 }
else {
return 
true;
};
}; 
Siendo:
Código PHP:
$row        =   mysql_fetch_array($rs); 
La línea 32, usando esa funcion obtengo erl siguiente mensaje:
Código HTML:
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in D:\IKEY SERVER\xampp\htdocs\VIRTUAL HOST\root\funciones.php on line 32