Bug #23439
closedPHP Warning in t3lib_spritemanager
0%
Description
i try to add a own sprite css with
$icons = array(
'extensions-myextension-icon1',
'extensions-myextension-icon2'
);
t3lib_SpriteManager::addIconSprite(
$icons,
t3lib_extMgm::siteRelPath('myextension') . 'myextension_sprite.css'
);
(example from http://blog.tolleiv.de/2010/07/typo3-4-4-sprites-in-your-extension/)
then i got a php Warning
PHP Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /.../t3lib/class.t3lib_spritemanager.php line 211
array_merge try to merge $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'] and $icons but $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'] is no array
testet with current trunk 8664
(issue imported from #M15543)
Files
Updated by Steffen Ritter about 14 years ago
thanks for your bug report, we currently found this one ourselves...
we think we better initialize the array
Updated by Steffen Kamper about 14 years ago
committed to svn
4_4 rev 9077
trunk rev 9078
Updated by Ernesto Baschny about 14 years ago
Steffen, you haven't seen the -v2 patch? I would prefer that solution, as it doesn't make sense to cast an unitialized array to an (array).