Issue Bug Closed

#23912taskcenter - wrongly created path for icon (in certain conditions)

Krystian Szymukowicz 11/02/10, 11:34 updated 12/13/14, 21:46

Description

PROBLEM:
The path for icon in taskcenter is created wtih:
$icon = $GLOBALS[‘BACK_PATH’] . ‘../’ . str_replace(PATH_site, ‘’, $absIconPath);

There are some edge situations when the PATH_site is equal to “/”. In that case the backslash from icon path will be removed and such path of icon generated:
http://example.com/typo3sysextsys_actionx-sys_action.png

SOLUTION:
Check if path is “/”

$icon = $GLOBALS[‘BACK_PATH’] . ‘../’ . (PATH_site == ‘/’ ? $absIconPath : str_replace(PATH_site, ‘’, $absIconPath));

(issue imported from #M16216)

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.