mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-23 13:54:26 +02:00
Revert "ActionController: Don't override X-Icinga-Title
when it's already set"
This reverts commit 4cff1feb8fe2231df6568e9d1d711540984c80fe. It's broken and obsolete since https://github.com/Icinga/ipl-web/pull/72.
This commit is contained in:
parent
e6eb1540c0
commit
bc6b17b850
@ -496,20 +496,18 @@ class ActionController extends Zend_Controller_Action
|
|||||||
$resp->setReloadCss(true);
|
$resp->setReloadCss(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($resp->getHeader('X-Icinga-Title') === null) {
|
if ($this->view->title) {
|
||||||
if ($this->view->title) {
|
if (preg_match('~[\r\n]~', $this->view->title)) {
|
||||||
if (preg_match('~[\r\n]~', $this->view->title)) {
|
// TODO: Innocent exception and error log for hack attempts
|
||||||
// TODO: Innocent exception and error log for hack attempts
|
throw new IcingaException('No way, guy');
|
||||||
throw new IcingaException('No way, guy');
|
|
||||||
}
|
|
||||||
$resp->setHeader(
|
|
||||||
'X-Icinga-Title',
|
|
||||||
rawurlencode($this->view->title . ' :: ' . $this->view->defaultTitle),
|
|
||||||
true
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
$resp->setHeader('X-Icinga-Title', rawurlencode($this->view->defaultTitle), true);
|
|
||||||
}
|
}
|
||||||
|
$resp->setHeader(
|
||||||
|
'X-Icinga-Title',
|
||||||
|
rawurlencode($this->view->title . ' :: ' . $this->view->defaultTitle),
|
||||||
|
true
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
$resp->setHeader('X-Icinga-Title', rawurlencode($this->view->defaultTitle), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
$layout = $this->_helper->layout();
|
$layout = $this->_helper->layout();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user