mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-12 23:14:18 +01:00
demove deprecated functions : replace ajax_page by AjaxPage
This commit is contained in:
@@ -28,7 +28,6 @@ $oAppContext = new ApplicationContext();
|
||||
$currentOrganization = utils::ReadParam('org_id', '');
|
||||
$operation = utils::ReadParam('operation', '');
|
||||
require_once(APPROOT.'/application/loginwebpage.class.inc.php');
|
||||
require_once(APPROOT.'/application/ajaxwebpage.class.inc.php');
|
||||
$bPortal = utils::ReadParam('portal', false);
|
||||
$sUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
|
||||
@@ -37,7 +36,7 @@ if ($operation == 'do_logoff')
|
||||
// Reload the same dummy page to let the "calling" page execute its 'onunload' method before performing the actual logoff.
|
||||
// Note the redirection MUST NOT be made via an HTTP "header" since onunload is called only when the actual content of the DOM
|
||||
// is replaced by some other content. So the "bouncing" page must provide some content (in our case a script making the redirection).
|
||||
$oPage = new ajax_page('');
|
||||
$oPage = new AjaxPage('');
|
||||
$oPage->add_script("window.location.href='{$sUrl}pages/logoff.php?portal=$bPortal'");
|
||||
$oPage->output();
|
||||
exit;
|
||||
|
||||
Reference in New Issue
Block a user