|
|
|
| Добрый день, уважаемые коллеги!
Бьюсь над устранением ошибки появившейся после смены хостинга работающего с php4.5 на php5.
Начала выдаваться ошибка (см.ниже) Тут видимо несоответствие типов данных.
Не могу сообразить как данные привести к общему виду, чтобы фукция не ругалась?
Warning: array_merge() [function.array-merge]: Argument #1 is not an array on line 22
function loadData()
{
$pgdir = SpawConfig::getStaticConfigValue("SPAW_ROOT").'plugins/';
if (is_dir($pgdir))
{
if ($dh = opendir($pgdir))
{
while (($pg = readdir($dh)) !== false)
{
if (file_exists($pgdir.$pg.'/lib/toolbars/'.$this->name.'.toolbar.php'))
{
// load toolbar file for each plugin
include($pgdir.$pg.'/lib/toolbars/'.$this->name.'.toolbar.php');
if ($pg != 'core')
{
// some plugin... append items to the end
$this->items = array_merge($this->items, $items);
}
else
{
// core... insert items in the beginning
$this->items = array_merge($items, $this->items);
}
unset($items);
}
}
closedir($dh);
}
}
}
|
| |
|
|