jeudi 23 juin 2016

Use of undefined constant inputarray - assumed 'inputarray' [duplicate]

This question already has an answer here:

at the beginning I am not into php so excuse me my lack of knowledge. I was moving my website from old to new server and after that I am struggling to get this website working.

From log:

[Wed Jun 22 00:50:31.462823 2016] [fcgid:warn] [pid 20222] [client:58083] mod_fcgid: stderr: PHP Notice: Use of undefined constant inputarray - assumed 'inputarray' in /home/nick/public_html/includes/mysql.config.php on line 16

mysql.config.php:

require_once('db.inc.php');
define('ADODB_ASSOC_CASE', 2);
define('ADODB_LANG', 'pl');

require_once('libs/adodb5/adodb.inc.php');
require_once('libs/adodb5/adodb-active-record.inc.php');

$ADODB_FETCH_MODE = ADODB_FETCH_ASSOC;

function &CountExecs( $db, $sql, $inputarray )
{
    global $EXECS;

    if (!is_array(inputarray)) $EXECS++;
    else if (is_array(reset($inputarray))) $EXECS += sizeof($inputarray);
    else $EXECS++;

    $null = null;
    return $null;
}

function CountCachedExecs( $db, $secs2cache, $sql, $inputarray )
{
    global $CACHED; $CACHED++;
}

$mysql = ADONewConnection('mysql');
$mysql -> Connect(DB_SERV, DB_USER, DB_PASS, DB_NAME);
ADOdb_Active_Record :: SetDatabaseAdapter( $mysql );

$mysql -> Execute("SET NAMES 'latin2'");

$mysql -> fnExecute = 'CountExecs';
$mysql -> fnCacheExecute = 'CountCachedExecs';
?>

Can somebody give a hint how i can get this fixed?

Thanks, Nick

Aucun commentaire:

Enregistrer un commentaire