Bug #20509 » 11194_sliced_rootline_with_extendTo.diff
class.tslib_fe.php (Arbeitskopie) | ||
---|---|---|
*/
|
||
function checkRootlineForIncludeSection() {
|
||
$c=count($this->rootLine);
|
||
$removeTheRestFlag=0;
|
||
$trunc=0; $remove=0; $rethought=0;
|
||
for ($a=0;$a<$c;$a++) {
|
||
if (!$this->checkPagerecordForIncludeSection($this->rootLine[$a])) {
|
||
// Add to page access failure history:
|
||
$this->pageAccessFailureHistory['sub_section'][] = $this->rootLine[$a];
|
||
$removeTheRestFlag=1;
|
||
$remove=1;
|
||
}
|
||
if ($this->rootLine[$a]['doktype']==6) {
|
||
if ($this->beUserLogin) { // If there is a backend user logged in, check if he has read access to the page:
|
||
$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid', 'pages', 'uid='.intval($this->id).' AND '.$GLOBALS['BE_USER']->getPagePermsClause(1)); // versionOL()?
|
||
list($isPage) = $GLOBALS['TYPO3_DB']->sql_fetch_row($res);
|
||
if (!$isPage) $removeTheRestFlag=1; // If there was no page selected, the user apparently did not have read access to the current PAGE (not position in rootline) and we set the remove-flag...
|
||
if (!$isPage) $remove=1; // If there was no page selected, the user apparently did not have read access to the current PAGE (not position in rootline) and we set the remove-flag...
|
||
} else { // Dont go here, if there is no backend user logged in.
|
||
$removeTheRestFlag=1;
|
||
$remove=1;
|
||
}
|
||
}
|
||
if ($removeTheRestFlag) {
|
||
if ($remove) {
|
||
if (!$this->rootLine[$a]['extendTo'])
|
||
$remove=$trunc;
|
||
else
|
||
$remove=$trunc=1;
|
||
$this->pageNotFound=2; // Page is 'not found' in case a subsection was found and not accessible, code 2
|
||
unset($this->rootLine[$a]);
|
||
$rethought=1;
|
||
}
|
||
}
|
||
return $removeTheRestFlag;
|
||
return $rethought;
|
||
}
|
||
/**
|
- « Previous
- 1
- 2
- Next »