I'm having a bit of trouble installing my vBulletin Forum, version 4.0 Beta 5.
I get this error on step 13 when it's "Updating style information for each style".
Warning:Invalid argument supplied for foreach() in /home/alij/public_html/includes/adminfunctions_template.php on line 2798."
And I can continue to the next step but when I finish the installation it won't actually show my forum.
Here is the code it's where it's saying the problem is: (Line 23) (Also this is not the full code, too big to put here)
Code: Select all
// ########################################### ##################################
/**
* Builds the stylecache and saves it into the datastore
*
* @return array $stylecache
*/
function build_style_datastore()
{
global $stylecache, $vbulletin;
if (!is_array($stylecache))
{
cache_styles();
// this should not ever be needed unless the user has edited the database
if (STYLECOUNT != sizeof($stylecache))
{
trigger_error('Invalid row in the style table', E_USER_ERROR);
}
}
$localstylecache = array();
foreach ($stylecache AS $styleid => $style) //*THIS IS THE LINE WHERE THE PROBLEM IS*
{
$localstyle = array();
$localstyle['styleid'] = $style['styleid'];
$localstyle['title'] = $style['title'];
$localstyle['parentid'] = $style['parentid'];
$localstyle['displayorder'] = $style['displayorder'];
$localstyle['userselect'] = $style['userselect'];
($hook = vBulletinHook::fetch_hook('admin_style_datastore')) ? eval($hook) : false;
$datastorecache["$localstyle[parentid]"]["$localstyle[displayorder]"][] = $localstyle;
}
build_datastore('stylecache', serialize($datastorecache), 1);
return $datastorecache;
}Thank you,
Ali J.