Bug #15559
closedAdminpanel - Javascript link to open backend causes error with IE and realurl
0%
Description
The javascript link within the adminpanel to open the TYPO3 backend does not work correctly on a subpage of the domain when using the extension 'realurl' and the Internet Explorer (6.0).
This is a general problem i could narrow down to the following: If you have a website with a basetag (e.g. http://yourdomain.com/) set and you are on a subpage (e.g. http://yourdomain.com/subpage/) the JS function call 'window.open(<relative_link>)' from the Adminpanel will result in:
- Firefox: http://yourdomain.com/<relative_link> which is correct
- Internet Explorer: http://yourdomain.com/subpage/<relative_link> which causes an error
It seems that the JS function call within the IE does not consider the basetag at all.
Having realurl enabled and using the link within the adminpanel to open the backend will cause the described error in IExplorer.
For me changing the line 381 in class.t3lib_tsfebeuserauth:
vHWin=window.open(\''.TYPO3_mainDir.'alt_main.php\',\''.md5('Typo3Backend-'.$GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename']).'\',\'status=1,menubar=1,scrollbars=1,resizable=1\');
into:
vHWin=window.open(\'http://'.$GLOBALS['HTTP_SERVER_VARS']['HTTP_HOST'].'/'.TYPO3_mainDir.'alt_main.php\',\''.md5('Typo3Backend-'.$GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename']).'\',\'status=1,menubar=1,scrollbars=1,resizable=1\');
fixed the problem, but I don't know if this is the best approach.
(issue imported from #M2472)
Files