il file config.php
mi da il seguente errore:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /membri2/scacchirakoforum/registrazione/include/config.php on line 36

il codice è il seguente:
Codice PHP:
<?php

error_reporting
(E_ALL);

$_CONFIG['host'] = "localhost";
$_CONFIG['user'] = "scacchirakoforum";
$_CONFIG['pass'] = "zio";
$_CONFIG['dbname'] = "articolo_autenticazione";

$_CONFIG['table_sessioni'] = "sessioni";
$_CONFIG['table_utenti'] = "utenti";

$_CONFIG['expire'] = 60;
$_CONFIG['regexpire'] = 24//in ore

$_CONFIG['check_table'] = array(
    
"username" => "check_username",
    
"password" => "check_global",
    
"name" => "check_global",
    
"surname" => "check_global",
    
"indirizzo" => "check_global",
    
"occupazione" => "check_global",
    
"mail" => "check_global"
);

function 
check_username($value){
    global 
$_CONFIG;
    
    
$value trim($value);
    if(
$value == "")
        return 
"Il campo non può essere lasciato vuoto";
    
$query mysql_query("
    SELECT id
    FROM "
.$_CONFIG['table_utenti']."
    WHERE username='"
.$value."'");
    if(
mysql_num_rows($query) != 0)
        return 
"Nome utente già utilizzato";
    
    return 
true;
}

function 
check_global($value){
    global 
$_CONFIG;
    
    
$value trim($value);
    if(
$value == "")
        return 
"Il campo non può essere lasciato vuoto";
    
    return 
true;
}


//--------------
define('AUTH_LOGGED'99);
define('AUTH_NOT_LOGGED'100);

define('AUTH_USE_COOKIE'101);
define('AUTH_USE_LINK'103);
define('AUTH_INVALID_PARAMS'104);
define('AUTH_LOGEDD_IN'105);
define('AUTH_FAILED'106);

define('REG_ERRORS'107);
define('REG_SUCCESS'108);
define('REG_FAILED'109);

$conn mysql_connect($_CONFIG['host'], $_CONFIG['user'], $_CONFIG['pass']) or die('Impossibile stabilire una connessione');
mysql_select_db($_CONFIG['dbname']);
?>
xkè???
grazie
ciao