PDA

View Full Version : Array errors and SQL errors


Richard-HH
10-01-2004, 08:45 AM
Hi !

These are the errors i get:

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in E:\inetpub\wwwroot\forums\global.php on line 27

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in E:\inetpub\wwwroot\forums\global.php on line 42

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in E:\inetpub\wwwroot\forums\global.php on line 49

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in E:\inetpub\wwwroot\forums\includes\init.php on line 517

Warning: Invalid argument supplied for foreach() in E:\inetpub\wwwroot\forums\includes\sessions.php on line 270

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in E:\inetpub\wwwroot\forums\includes\functions.php on line 3616

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in E:\inetpub\wwwroot\forums\includes\functions.php on line 3616

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in E:\inetpub\wwwroot\forums\includes\functions.php on line 3616



Additional i get this database error:

Datenbankfehler in vBulletin :

Ungueltige SQL-Abfrage:
SELECT * FROM style
WHERE (styleid = 2)
OR styleid =
ORDER BY styleid DESC
LIMIT 1

mysql error: You have an error in your SQL syntax near 'ORDER BY styleid DESC
LIMIT 1' at line 4

mysql error number: 1064



As you can see, the "or styleid=" is empty.





Ok, here is what ive done/envorinment:

Server Windows 2000
PHP 5.01
Apache 2
MySql 4.0.1

VB was 2.2.5, upgraded to 2.3.5, upgraded to 3.03
Upgrade is fine, forum alone is running fine.

Followed the CMPS install guide wordly a bazillion times, all time same error.

Gets annoying...plz help !
Tnx !!

Richard
www.beisammen.de (there is the old server, i prepare the change here locally).

Richard-HH
10-01-2004, 08:47 AM
Oups...addition:

My global.php:

<?php
/*======================================================================*\
|| #################################################################### ||
|| # vBulletin 3.0.3 - Licence Number (CUTTED)
|| # ---------------------------------------------------------------- # ||
|| # Copyright ©2000–2004 Jelsoft Enterprises Ltd. All Rights Reserved. ||
|| # This file may not be redistributed in whole or significant part. # ||
|| # ---------------- VBULLETIN IS NOT FREE SOFTWARE ---------------- # ||
|| # http://www.vbulletin.com | http://www.vbulletin.com/license.html # ||
|| #################################################################### ||
\*======================================================================*/

// identify where we are
define('VB_AREA', 'Forum');

// #############################################################################
// Start initialisation

if (defined('VBA_PORTAL'))
{
$phrasegroups = array_merge($phrasegroups,
array(
'calendar',
'adv_portal',
'postbit'
)
);

$specialtemplates = array_merge($specialtemplates,
array(
'adv_modules',
'adv_portal_opts',
'attachmentcache',
'bbcodecache',
'birthdaycache',
'eventcache',
'iconcache',
'maxloggedin',
'smiliecache',
'userstats'
)
);

$globaltemplates = array_merge($globaltemplates,
array(
'adv_portal',
'adv_portal_footer'
)
);
}

require_once('./includes/init.php');

// #############################################################################
// Start functions

CUT






My index.php (the renamed cmps_index.php in the level of the FORUMS path):
<?php
// ++=========================================================================++
// || vBadvanced CMPS v1.0 RC2 ||
// || © 2003-2004 vBadvanced.com & PlurPlanet, LLC - All Rights Reserved ||
// || This file may not be redistributed in whole or significant part. ||
// || http://vbadvanced.com ||
// ++ ========================================================================++

error_reporting(E_ALL & ~E_NOTICE);
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'index');
define('VBA_PORTAL', true);

// ============================================
// Enter the full path to your forum here
// Example: /home/vbadvanced/public_html/forum
// ============================================

chdir('E:/inetpub/wwwroot/forums');

// ============================================
// No Further Editing Necessary!
// ============================================

require_once('./global.php');

print_portal_output($home);

?>

Our Sponsors
 

Brian
10-01-2004, 10:09 AM
The array_merge error is a bug that's caused by PHP5. To fix it, open your cmps_index.php file and look for:
require_once('./global.php');

Right Above that, Add:
$phrasegroups = array();
$specialtemplates = array();
$globaltemplates = array();


As for the SQL error, please try the fix posted in this thread (http://vbadvanced.com/forum/showpost.php?p=5856&postcount=13) and see if that helps.

Richard-HH
10-01-2004, 10:17 AM
WOOT !!

That did it (inserting the block in the index.php file)


Brian, what u drink my friend ? : :p


Tnx a ton !!

Laters...

Our Sponsors
 

Cube
11-14-2004, 02:49 PM
Thanx I had the same problem
Thanx Brain for the solution.