mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-28 17:48:56 +01:00
fix sometimes not working redirect to login page (session could not be verified), because inline script is not allowed by our content-security-policy, redirecting top window now in login.js
This commit is contained in:
parent
4562b53b1b
commit
7eff188dcf
@ -331,12 +331,7 @@ class egw extends egw_minimal
|
||||
if (egw_session::get_sessionid()) $redirect .= 'cd=10&';
|
||||
}
|
||||
if ($relpath) $redirect .= 'phpgw_forward='.urlencode($relpath.(!empty($query) ? '?'.$query : ''));
|
||||
//Header('Location: '.$GLOBALS['egw_info']['server']['webserver_url'].$redirect);
|
||||
// do NOT redirect, but set top.location, as this works in framed template too
|
||||
$redirect = $GLOBALS['egw_info']['server']['webserver_url'].$redirect;
|
||||
|
||||
echo "<html>\n<head>\n<script type='text/javascript'>top.location='$redirect';</script>\n</head>\n";
|
||||
exit;
|
||||
self::redirect_link($redirect);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -8,6 +8,9 @@
|
||||
* @version $Id$
|
||||
*/
|
||||
|
||||
/* if login page is not in top window, set top windows location to it */
|
||||
if (top !== window) top.location = window.location;
|
||||
|
||||
egw_LAB.wait(function()
|
||||
{
|
||||
$j(document).ready(function()
|
||||
|
Loading…
Reference in New Issue
Block a user