static function textPage($text) { global $parametersMod; global $site; $site->requireTemplate('standard/content_management/widgets/text_photos/title/template.php'); $site->requireTemplate('standard/content_management/widgets/text_photos/text/template.php'); $answer = ''; $answer .= \Modules\standard\content_management\Widgets\text_photos\title\Template::generateHtml($parametersMod->getValue('community', 'newsletter', 'subscription_translations', 'newsletter'), 1); $answer .= \Modules\standard\content_management\Widgets\text_photos\text\Template::generateHtml($text); return $answer; }
public static function searchResult($title, $foundElementsCombined, $foundElements) { global $site; global $parametersMod; $site->requireTemplate('standard/content_management/widgets/text_photos/title/template.php'); $site->requireTemplate('standard/content_management/widgets/text_photos/text/template.php'); $answer = ''; $answer .= \Modules\standard\content_management\Widgets\text_photos\title\Template::generateHtml($title, 1); $answer .= \Modules\standard\content_management\Widgets\text_photos\text\Template::generateHtml(Template::elementsList($foundElementsCombined)); foreach ($foundElements as $zoneKey => $zoneBunch) { $answer .= \Modules\standard\content_management\Widgets\text_photos\title\Template::generateHtml($site->getZone($zoneKey)->getTitle(), 2); $answer .= \Modules\standard\content_management\Widgets\text_photos\text\Template::generateHtml(Template::elementsList($zoneBunch)); } return $answer; }
public static function zone($zone, $maxDepth = null) { global $parametersMod; $answer = ''; if ($parametersMod->getValue('administrator', 'sitemap', 'options', 'include_zone_title')) { $answer .= \Modules\standard\content_management\Widgets\text_photos\title\Template::generateHtml($zone->getTitle(), 2); } $elements = $zone->getElements(); if (sizeof($elements) > 0) { $curDepth = $elements[0]->getDepth(); $tmpHtml = Template::tepElements($zone, $elements, $curDepth, $maxDepth); $answer .= \Modules\standard\content_management\Widgets\text_photos\text\Template::generateHtml($tmpHtml); } return $answer; }
/** * * @return string - The content of current page (in management state management tools are automatically added). * */ public function generateContent() { $answer = ''; if ($this->currentZone) { if ($this->error404) { $this->requireTemplate('standard/content_management/widgets/text_photos/text/template.php'); $answer .= \Modules\standard\content_management\widgets\text_photos\text\Template::generateHtml($this->error404Message()); global $log; $log->log("system", "error404", $this->getCurrentUrl() . " " . $this->error404Message()); } else { if ($this->managementState()) { if (!isset($_SESSION['backend_session']['user_id'])) { $answer = '<script type="text/javascript">window.location = \'' . BASE_URL . BACKEND_MAIN_FILE . '\';</script>'; } else { $answer .= $this->getZone($this->currentZone)->getCurrentElement()->generateManagement(); } } else { $answer .= $this->getZone($this->currentZone)->getCurrentElement()->generateContent(); } } } return $answer; }
public static function renewRegistrationError() { global $site; $site->requireTemplate('standard/content_management/widgets/text_photos/title/template.php'); $site->requireTemplate('standard/content_management/widgets/text_photos/text/template.php'); global $parametersMod; $answer = ''; $answer .= \Modules\standard\content_management\Widgets\text_photos\title\Template::generateHtml($title = $parametersMod->getValue('community', 'user', 'translations', 'title_registration'), $level = 1, $layout = null); $text = $parametersMod->getValue('community', 'user', 'translations', 'text_account_renewal_error'); $answer .= \Modules\standard\content_management\Widgets\text_photos\text\Template::generateHtml($text, $layout = null); return $answer; }