/** * return void */ protected function collectPages() { $rootline = $this->pageRepository->getRootLine($GLOBALS['TSFE']->id); foreach ($rootline as $page) { $this->collectPage($this->pageRepository->getPage($page['uid'])); } $this->generateUrlCollection(); }
/** * generates a string for the URL * * @param array $uParts the parts of the URL * @return string the URL string */ function getUrlStr($uParts) { $baseURL = $this->getBaseURL(); if (is_array($uParts) && GeneralUtility::getIndpEnv('TYPO3_HOST_ONLY') == $uParts['host']) { $m = array(); // do we have an id? if (preg_match('/(?:^|&)id=([0-9a-z_]+)/', $uParts['query'], $m)) { $isInt = MathUtility::canBeInterpretedAsInteger($m[1]); if ($isInt) { $uid = intval($m[1]); } else { $uid = $this->sys_page->getPageIdFromAlias($m[1]); } $temp_root_line = $this->sys_page->getRootLine($uid); $temp_page = array_shift($temp_root_line); // array_shift reverses the array (rootline has numeric index in the wrong order!) $temp_root_line = array_reverse($temp_root_line); $query = preg_replace('/(?:^|&)id=([0-9a-z_]+)/', '', $uParts['query']); $urlstr = GeneralUtility::fixed_lgd_cs($temp_page['title'], 50) . GeneralUtility::fixed_lgd_cs($query ? ' / ' . $query : '', 20); } else { $urlstr = $baseURL . substr($uParts['path'], 1); $urlstr .= $uParts['query'] ? '?' . $uParts['query'] : ''; $urlstr .= $uParts['fragment'] ? '#' . $uParts['fragment'] : ''; } } else { $urlstr = ($uParts['host'] ? $uParts['scheme'] . '://' . $uParts['host'] : $baseURL) . $uParts['path']; $urlstr .= $uParts['query'] ? '?' . $uParts['query'] : ''; $urlstr .= $uParts['fragment'] ? '#' . $uParts['fragment'] : ''; } return $urlstr; }
/** * Checks if the the page is any child of the root page. * * @param int $pid * @param int $rootPid * @return boolean */ protected function isAnyChildOf($pid, $rootPid) { $this->createSysPageIfNecessary(); $rootLine = $this->sysPage->getRootLine($pid); foreach ($rootLine as $page) { if ($page['uid'] == $rootPid) { return true; } } return false; }
/** * @return array */ protected function getTypoScriptTemplatesInRootline() { $rootline = $this->pageRepository->getRootLine($this->configurationManager->getCurrentPageId()); $pageUids = array(); foreach ($rootline as $page) { $pageUids[] = $page['uid']; } if (empty($pageUids)) { return array(); } $condition = 'deleted = 0 AND hidden = 0 AND starttime <= :starttime AND (endtime = 0 OR endtime > :endtime) AND pid IN (' . implode(',', $pageUids) . ')'; $parameters = array(':starttime' => $GLOBALS['SIM_ACCESS_TIME'], ':endtime' => $GLOBALS['SIM_ACCESS_TIME']); $rootTypoScriptTemplates = $this->recordService->preparedGet('sys_template', 'pid', $condition, $parameters); return $rootTypoScriptTemplates; }
/** * Wrapper for \TYPO3\CMS\Frontend\Page\PageRepository::getRootLine() * * @param integer $pageUid * @param string $MP * @param boolean $reverse * @return array */ public function getRootLine($pageUid = NULL, $MP = NULL, $reverse = FALSE) { if (NULL === $pageUid) { $pageUid = $GLOBALS['TSFE']->id; } if (NULL === $MP) { $MP = GeneralUtility::_GP('MP'); if (TRUE === empty($MP)) { $MP = ''; } } $key = md5($pageUid . $MP . (string) $reverse); if (FALSE === isset(self::$cachedRootLines[$key])) { $rootLine = self::$pageSelect->getRootLine($pageUid, $MP); if (TRUE === $reverse) { $rootLine = array_reverse($rootLine); } self::$cachedRootLines[$key] = $rootLine; } return self::$cachedRootLines[$key]; }
protected function findFirstWithoutHostByDoktype($doktype) { /** @var array<\R3H6\Error404page\Domain\Model\Page> $pages */ $pages = $this->findAllByDoktype($doktype); $domains = $this->domainRepository->findAll(); $blackList = array(); foreach ($domains as $domain) { $blackList[] = $domain['pid']; } foreach ($pages as $page) { $rootLine = $this->pageRepository->getRootLine($page->getUid()); foreach ($rootLine as $parentPage) { if (in_array($parentPage['uid'], $blackList)) { continue 2; // It's not this page, try next! } } return $page; } return null; }
/** * Shows the content of configuration module * compiling the configuration form and fill it with default values * * @return string The compiled content of the module. */ protected function moduleContent() { $configArray[1] = array('box-1' => $this->getLanguageService()->getLL('configure_default_headers'), 'from_email' => array('string', DirectMailUtility::fName('from_email'), $this->getLanguageService()->getLL('from_email.description') . '<br />' . $this->getLanguageService()->getLL('from_email.details')), 'from_name' => array('string', DirectMailUtility::fName('from_name'), $this->getLanguageService()->getLL('from_name.description') . '<br />' . $this->getLanguageService()->getLL('from_name.details')), 'replyto_email' => array('string', DirectMailUtility::fName('replyto_email'), $this->getLanguageService()->getLL('replyto_email.description') . '<br />' . $this->getLanguageService()->getLL('replyto_email.details')), 'replyto_name' => array('string', DirectMailUtility::fName('replyto_name'), $this->getLanguageService()->getLL('replyto_name.description') . '<br />' . $this->getLanguageService()->getLL('replyto_name.details')), 'return_path' => array('string', DirectMailUtility::fName('return_path'), $this->getLanguageService()->getLL('return_path.description') . '<br />' . $this->getLanguageService()->getLL('return_path.details')), 'organisation' => array('string', DirectMailUtility::fName('organisation'), $this->getLanguageService()->getLL('organisation.description') . '<br />' . $this->getLanguageService()->getLL('organisation.details')), 'priority' => array('select', DirectMailUtility::fName('priority'), $this->getLanguageService()->getLL('priority.description') . '<br />' . $this->getLanguageService()->getLL('priority.details'), array(3 => $this->getLanguageService()->getLL('configure_priority_normal'), 1 => $this->getLanguageService()->getLL('configure_priority_high'), 5 => $this->getLanguageService()->getLL('configure_priority_low')))); $configArray[2] = array('box-2' => $this->getLanguageService()->getLL('configure_default_content'), 'sendOptions' => array('select', DirectMailUtility::fName('sendOptions'), $this->getLanguageService()->getLL('sendOptions.description') . '<br />' . $this->getLanguageService()->getLL('sendOptions.details'), array(3 => $this->getLanguageService()->getLL('configure_plain_and_html'), 1 => $this->getLanguageService()->getLL('configure_plain_only'), 2 => $this->getLanguageService()->getLL('configure_html_only'))), 'includeMedia' => array('check', DirectMailUtility::fName('includeMedia'), $this->getLanguageService()->getLL('includeMedia.description') . '<br />' . $this->getLanguageService()->getLL('includeMedia.details')), 'flowedFormat' => array('check', DirectMailUtility::fName('flowedFormat'), $this->getLanguageService()->getLL('flowedFormat.description') . '<br />' . $this->getLanguageService()->getLL('flowedFormat.details'))); $configArray[3] = array('box-3' => $this->getLanguageService()->getLL('configure_default_fetching'), 'HTMLParams' => array('short', DirectMailUtility::fName('HTMLParams'), $this->getLanguageService()->getLL('configure_HTMLParams_description') . '<br />' . $this->getLanguageService()->getLL('configure_HTMLParams_details')), 'plainParams' => array('short', DirectMailUtility::fName('plainParams'), $this->getLanguageService()->getLL('configure_plainParams_description') . '<br />' . $this->getLanguageService()->getLL('configure_plainParams_details')), 'use_domain' => array('select', DirectMailUtility::fName('use_domain'), $this->getLanguageService()->getLL('use_domain.description') . '<br />' . $this->getLanguageService()->getLL('use_domain.details'), array(0 => ''))); $configArray[4] = array('box-4' => $this->getLanguageService()->getLL('configure_options_encoding'), 'quick_mail_encoding' => array('select', $this->getLanguageService()->getLL('configure_quickmail_encoding'), $this->getLanguageService()->getLL('configure_quickmail_encoding_description'), array('quoted-printable' => 'quoted-printable', 'base64' => 'base64', '8bit' => '8bit')), 'direct_mail_encoding' => array('select', $this->getLanguageService()->getLL('configure_directmail_encoding'), $this->getLanguageService()->getLL('configure_directmail_encoding_description'), array('quoted-printable' => 'quoted-printable', 'base64' => 'base64', '8bit' => '8bit')), 'quick_mail_charset' => array('short', $this->getLanguageService()->getLL('configure_quickmail_charset'), $this->getLanguageService()->getLL('configure_quickmail_charset_description')), 'direct_mail_charset' => array('short', $this->getLanguageService()->getLL('configure_directmail_charset'), $this->getLanguageService()->getLL('configure_directmail_charset_description'))); $configArray[5] = array('box-5' => $this->getLanguageService()->getLL('configure_options_links'), 'use_rdct' => array('check', DirectMailUtility::fName('use_rdct'), $this->getLanguageService()->getLL('use_rdct.description') . '<br />' . $this->getLanguageService()->getLL('use_rdct.details') . '<br />' . $this->getLanguageService()->getLL('configure_options_links_rdct')), 'long_link_mode' => array('check', DirectMailUtility::fName('long_link_mode'), $this->getLanguageService()->getLL('long_link_mode.description')), 'enable_jump_url' => array('check', $this->getLanguageService()->getLL('configure_options_links_jumpurl'), $this->getLanguageService()->getLL('configure_options_links_jumpurl_description')), 'jumpurl_tracking_privacy' => array('check', $this->getLanguageService()->getLL('configure_jumpurl_tracking_privacy'), $this->getLanguageService()->getLL('configure_jumpurl_tracking_privacy_description')), 'enable_mailto_jump_url' => array('check', $this->getLanguageService()->getLL('configure_options_mailto_jumpurl'), $this->getLanguageService()->getLL('configure_options_mailto_jumpurl_description')), 'authcode_fieldList' => array('short', DirectMailUtility::fName('authcode_fieldList'), $this->getLanguageService()->getLL('authcode_fieldList.description'))); $configArray[6] = array('box-6' => $this->getLanguageService()->getLL('configure_options_additional'), 'http_username' => array('short', $this->getLanguageService()->getLL('configure_http_username'), $this->getLanguageService()->getLL('configure_http_username_description') . '<br />' . $this->getLanguageService()->getLL('configure_http_username_details')), 'http_password' => array('short', $this->getLanguageService()->getLL('configure_http_password'), $this->getLanguageService()->getLL('configure_http_password_description')), 'simulate_usergroup' => array('short', $this->getLanguageService()->getLL('configure_simulate_usergroup'), $this->getLanguageService()->getLL('configure_simulate_usergroup_description') . '<br />' . $this->getLanguageService()->getLL('configure_simulate_usergroup_details')), 'userTable' => array('short', $this->getLanguageService()->getLL('configure_user_table'), $this->getLanguageService()->getLL('configure_user_table_description')), 'test_tt_address_uids' => array('short', $this->getLanguageService()->getLL('configure_test_tt_address_uids'), $this->getLanguageService()->getLL('configure_test_tt_address_uids_description')), 'test_dmail_group_uids' => array('short', $this->getLanguageService()->getLL('configure_test_dmail_group_uids'), $this->getLanguageService()->getLL('configure_test_dmail_group_uids_description')), 'testmail' => array('short', $this->getLanguageService()->getLL('configure_testmail'), $this->getLanguageService()->getLL('configure_testmail_description'))); // Set default values if (!isset($this->implodedParams['plainParams'])) { $this->implodedParams['plainParams'] = '&type=99'; } if (!isset($this->implodedParams['quick_mail_charset'])) { $this->implodedParams['quick_mail_charset'] = 'utf-8'; } if (!isset($this->implodedParams['direct_mail_charset'])) { $this->implodedParams['direct_mail_charset'] = 'iso-8859-1'; } // Set domain selection list $rootline = $this->sys_page->getRootLine($this->id); $rootlineId = array(); foreach ($rootline as $rArr) { $rootlineId[] = $rArr['uid']; } $res_domain = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid,domainName', 'sys_domain', 'sys_domain.pid in (' . implode(',', $rootlineId) . ')' . BackendUtility::deleteClause('sys_domain')); while ($row_domain = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_domain)) { $configArray[3]['use_domain']['3'][$row_domain['uid']] = $row_domain['domainName']; } $GLOBALS["TYPO3_DB"]->sql_free_result($res_domain); $this->configArray_length = count($configArray); $form = ''; for ($i = 1; $i <= count($configArray); $i++) { $form .= $this->makeConfigForm($configArray[$i], $this->implodedParams, 'pageTS'); } $form .= '<input type="submit" name="submit" value="Update configuration" />'; return str_replace('Update configuration', $this->getLanguageService()->getLL('configure_update_configuration'), $form); }
/** * Get array of folders with news module * * @param Tx_MooxNews_Domain_Model_Dto_AdministrationDemand $demand * @return array folders with news module */ public function getFolders($demand) { global $BE_USER; $folders = array(); if ($demand->getType() != '' && false) { $typeStmt = 'AND news_type="' . $demand->getType() . '"'; } $query = array('SELECT' => '*', 'FROM' => 'pages', 'WHERE' => $BE_USER->getPagePermsClause(1) . ' AND deleted=0 AND doktype=254 AND module="mxnews"' . $typeStmt); $pages = $GLOBALS['TYPO3_DB']->exec_SELECT_queryArray($query); $folderCnt = 0; while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($pages)) { $folders[$folderCnt] = $row; $rootline = $this->pageRepository->getRootLine($row['uid']); foreach ($rootline as $rootlinepage) { if ($rootlinepage['is_siteroot']) { $rootlinepage['title'] = $rootlinepage['title']; $folders[$folderCnt]['rootpage'] = $rootlinepage; break; } } if (!$folders[$folderCnt]['rootpage']) { $folders[$folderCnt]['rootpage'] = $rootline[0]; } $rootline = array_reverse($rootline); if (isset($rootline[count($rootline) - 2])) { $pageInfo = $this->pageRepository->getPage((int) $rootline[count($rootline) - 2]['uid']); if ($pageInfo['module'] == 'mxnews') { $folders[$folderCnt]['folder'] = $pageInfo['uid']; } } $folders[$folderCnt]['rootline'] = $rootline; $folderCnt++; } usort($folders, "sortByFolderAndTitle"); $folders = array_reverse($folders); return $folders; }
/** * Setting the language key that will be used by the current page. * In this function it should be checked, 1) that this language exists, 2) that a page_overlay_record exists, .. and if not the default language, 0 (zero), should be set. * * @return void * @access private * @todo Define visibility */ public function settingLanguage() { if (is_array($this->TYPO3_CONF_VARS['SC_OPTIONS']['tslib/class.tslib_fe.php']['settingLanguage_preProcess'])) { $_params = array(); foreach ($this->TYPO3_CONF_VARS['SC_OPTIONS']['tslib/class.tslib_fe.php']['settingLanguage_preProcess'] as $_funcRef) { \TYPO3\CMS\Core\Utility\GeneralUtility::callUserFunction($_funcRef, $_params, $this); } } // Get values from TypoScript: $this->sys_language_uid = $this->sys_language_content = intval($this->config['config']['sys_language_uid']); list($this->sys_language_mode, $sys_language_content) = \TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(';', $this->config['config']['sys_language_mode']); $this->sys_language_contentOL = $this->config['config']['sys_language_overlay']; // If sys_language_uid is set to another language than default: if ($this->sys_language_uid > 0) { // check whether a shortcut is overwritten by a translated page // we can only do this now, as this is the place where we get // to know about translations $this->checkTranslatedShortcut(); // Request the overlay record for the sys_language_uid: $olRec = $this->sys_page->getPageOverlay($this->id, $this->sys_language_uid); if (!count($olRec)) { // If no OL record exists and a foreign language is asked for... if ($this->sys_language_uid) { // If requested translation is not available: if (\TYPO3\CMS\Core\Utility\GeneralUtility::hideIfNotTranslated($this->page['l18n_cfg'])) { $this->pageNotFoundAndExit('Page is not available in the requested language.'); } else { switch ((string) $this->sys_language_mode) { case 'strict': $this->pageNotFoundAndExit('Page is not available in the requested language (strict).'); break; case 'content_fallback': $fallBackOrder = \TYPO3\CMS\Core\Utility\GeneralUtility::intExplode(',', $sys_language_content); foreach ($fallBackOrder as $orderValue) { if (!strcmp($orderValue, '0') || count($this->sys_page->getPageOverlay($this->id, $orderValue))) { $this->sys_language_content = $orderValue; // Setting content uid (but leaving the sys_language_uid) break; } } break; case 'ignore': $this->sys_language_content = $this->sys_language_uid; break; default: // Default is that everything defaults to the default language... $this->sys_language_uid = $this->sys_language_content = 0; break; } } } } else { // Setting sys_language if an overlay record was found (which it is only if a language is used) $this->page = $this->sys_page->getPageOverlay($this->page, $this->sys_language_uid); } } // Setting sys_language_uid inside sys-page: $this->sys_page->sys_language_uid = $this->sys_language_uid; // If default translation is not available: if ((!$this->sys_language_uid || !$this->sys_language_content) && $this->page['l18n_cfg'] & 1) { $message = 'Page is not available in default language.'; \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog($message, 'cms', \TYPO3\CMS\Core\Utility\GeneralUtility::SYSLOG_SEVERITY_ERROR); $this->pageNotFoundAndExit($message); } // Updating content of the two rootLines IF the language key is set! if ($this->sys_language_uid && is_array($this->tmpl->rootLine)) { $this->tmpl->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); } if ($this->sys_language_uid && is_array($this->rootLine)) { $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); } // Finding the ISO code: if (\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('static_info_tables') && $this->sys_language_content) { // using sys_language_content because the ISO code only (currently) affect content selection from FlexForms - which should follow "sys_language_content" $sys_language_row = $this->sys_page->getRawRecord('sys_language', $this->sys_language_content, 'static_lang_isocode'); if (is_array($sys_language_row) && $sys_language_row['static_lang_isocode']) { $stLrow = $this->sys_page->getRawRecord('static_languages', $sys_language_row['static_lang_isocode'], 'lg_iso_2'); $this->sys_language_isocode = $stLrow['lg_iso_2']; } } // Setting softMergeIfNotBlank: $table_fields = \TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', $this->config['config']['sys_language_softMergeIfNotBlank'], 1); foreach ($table_fields as $TF) { list($tN, $fN) = explode(':', $TF); $this->TCAcachedExtras[$tN]['l10n_mode'][$fN] = 'mergeIfNotBlank'; } // Setting softExclude: $table_fields = \TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', $this->config['config']['sys_language_softExclude'], 1); foreach ($table_fields as $TF) { list($tN, $fN) = explode(':', $TF); $this->TCAcachedExtras[$tN]['l10n_mode'][$fN] = 'exclude'; } if (is_array($this->TYPO3_CONF_VARS['SC_OPTIONS']['tslib/class.tslib_fe.php']['settingLanguage_postProcess'])) { $_params = array(); foreach ($this->TYPO3_CONF_VARS['SC_OPTIONS']['tslib/class.tslib_fe.php']['settingLanguage_postProcess'] as $_funcRef) { \TYPO3\CMS\Core\Utility\GeneralUtility::callUserFunction($_funcRef, $_params, $this); } } }
/** * Obtains domain data for the target pid. Domain data is an array with * 'pid', 'domainName' and 'forced' members (see sys_domain table for * meaning of these fields. * * @param int $targetPid Target page id * @return mixed Return domain data or NULL */ public function getDomainDataForPid($targetPid) { // Using array_key_exists() here, nice $result can be NULL // (happens, if there's no domain records defined) if (!array_key_exists($targetPid, $this->domainDataCache)) { $result = NULL; $sysDomainData = $this->getSysDomainCache(); $rootline = $this->sys_page->getRootLine($targetPid); // walk the rootline downwards from the target page // to the root page, until a domain record is found foreach ($rootline as $pageInRootline) { $pidInRootline = $pageInRootline['uid']; if (isset($sysDomainData[$pidInRootline])) { $result = $sysDomainData[$pidInRootline]; break; } } $this->domainDataCache[$targetPid] = $result; } return $this->domainDataCache[$targetPid]; }
/** * Gets the page and rootline arrays based on the id, $this->id * * If the id does not correspond to a proper page, the 'previous' valid page in the rootline is found * If the page is a shortcut (doktype=4), the ->id is loaded with that id * * Whether or not the ->id is changed to the shortcut id or the previous id in rootline (eg if a page is hidden), the ->page-array and ->rootline is found and must also be valid. * * Sets or manipulates internal variables such as: $this->id, $this->page, $this->rootLine, $this->MP, $this->pageNotFound * * @return void * @access private * @todo Define visibility */ public function getPageAndRootline() { $this->page = $this->sys_page->getPage($this->id); if (!count($this->page)) { // If no page, we try to find the page before in the rootLine. // Page is 'not found' in case the id itself was not an accessible page. code 1 $this->pageNotFound = 1; $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); if (count($this->rootLine)) { $c = count($this->rootLine) - 1; while ($c > 0) { // Add to page access failure history: $this->pageAccessFailureHistory['direct_access'][] = $this->rootLine[$c]; // Decrease to next page in rootline and check the access to that, if OK, set as page record and ID value. $c--; $this->id = $this->rootLine[$c]['uid']; $this->page = $this->sys_page->getPage($this->id); if (count($this->page)) { break; } } } // If still no page... if (!count($this->page)) { $message = 'The requested page does not exist!'; if ($this->TYPO3_CONF_VARS['FE']['pageNotFound_handling']) { $this->pageNotFoundAndExit($message); } else { \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog($message, 'cms', \TYPO3\CMS\Core\Utility\GeneralUtility::SYSLOG_SEVERITY_ERROR); throw new \TYPO3\CMS\Core\Error\Http\PageNotFoundException($message, 1301648780); } } } // Spacer is not accessible in frontend if ($this->page['doktype'] == \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER) { $message = 'The requested page does not exist!'; if ($this->TYPO3_CONF_VARS['FE']['pageNotFound_handling']) { $this->pageNotFoundAndExit($message); } else { \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog($message, 'cms', \TYPO3\CMS\Core\Utility\GeneralUtility::SYSLOG_SEVERITY_ERROR); throw new \TYPO3\CMS\Core\Error\Http\PageNotFoundException($message, 1301648781); } } // Is the ID a link to another page?? if ($this->page['doktype'] == \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT) { // We need to clear MP if the page is a shortcut. Reason is if the short cut goes to another page, then we LEAVE the rootline which the MP expects. $this->MP = ''; // saving the page so that we can check later - when we know // about languages - whether we took the correct shortcut or // whether a translation of the page overwrites the shortcut // target and we need to follow the new target $this->originalShortcutPage = $this->page; $this->page = $this->getPageShortcut($this->page['shortcut'], $this->page['shortcut_mode'], $this->page['uid']); $this->id = $this->page['uid']; } // Gets the rootLine $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); // If not rootline we're off... if (!count($this->rootLine)) { $ws = $this->whichWorkspace(); if ($this->sys_page->error_getRootLine_failPid == -1 && $ws) { $this->sys_page->versioningPreview = TRUE; $this->versioningWorkspaceId = $ws; $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); } if (!count($this->rootLine)) { $message = 'The requested page didn\'t have a proper connection to the tree-root!'; if ($this->checkPageUnavailableHandler()) { $this->pageUnavailableAndExit($message); } else { $rootline = '(' . $this->sys_page->error_getRootLine . ')'; \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog($message, 'cms', \TYPO3\CMS\Core\Utility\GeneralUtility::SYSLOG_SEVERITY_ERROR); throw new \TYPO3\CMS\Core\Error\Http\ServiceUnavailableException($message . '<br /><br />' . $rootline, 1301648167); } } $this->fePreview = 1; } // Checking for include section regarding the hidden/starttime/endtime/fe_user (that is access control of a whole subbranch!) if ($this->checkRootlineForIncludeSection()) { if (!count($this->rootLine)) { $message = 'The requested page was not accessible!'; if ($this->checkPageUnavailableHandler()) { $this->pageUnavailableAndExit($message); } else { \TYPO3\CMS\Core\Utility\GeneralUtility::sysLog($message, 'cms', \TYPO3\CMS\Core\Utility\GeneralUtility::SYSLOG_SEVERITY_ERROR); throw new \TYPO3\CMS\Core\Error\Http\ServiceUnavailableException($message, 1301648234); } } else { $el = reset($this->rootLine); $this->id = $el['uid']; $this->page = $this->sys_page->getPage($this->id); $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); } } }