42 global $TEXT, $MENU, $HEADING, $MESSAGE, $section_id;
44 $oLEPTON = LEPTON_frontend::getInstance();
47 if ($oLEPTON->page_access_denied ===
true)
49 echo $MESSAGE[
'FRONTEND_SORRY_NO_VIEWING_PERMISSIONS'];
54 if ($oLEPTON->page_no_active_sections ===
true)
56 echo $MESSAGE[
'FRONTEND_SORRY_NO_ACTIVE_SECTIONS'];
62 if (!defined(
'PAGE_CONTENT') || $block != 1)
64 $page_id = intval( $oLEPTON->page_id );
67 $_SESSION[
'PAGE_ID' ] = !isset( $_SESSION[
'PAGE_ID' ] ) ? $page_id : $_SESSION[
'PAGE_ID' ];
70 if (($page_id != 0 ) && ($_SESSION[
'PAGE_ID' ] <> $page_id))
72 $_SESSION[
'PAGE_ID' ] = $page_id;
78 "SELECT section_id, module, publ_start, publ_end from ".TABLE_PREFIX.
"sections WHERE page_id = ".$page_id.
" AND block = '".$block.
"' ORDER BY position",
85 foreach ($aSections as $section)
89 if ( !( ( $now <= $section[
'publ_end' ] || $section[
'publ_end' ] == 0 ) && ( $now >= $section[
'publ_start' ] || $section[
'publ_start' ] == 0 ) ) )
93 $section_id = $section[
'section_id' ];
94 $module = $section[
'module' ];
97 if ( defined(
'SEC_ANCHOR' ) && SEC_ANCHOR !=
'' )
99 echo
'<a class="section_anchor" id="' . SEC_ANCHOR . $section_id .
'"></a>';
102 if ( file_exists( LEPTON_PATH .
'/modules/' . $module .
'/view.php' ) )
106 require LEPTON_PATH .
'/modules/' . $module .
'/view.php';
107 $content = ob_get_clean();
120 if (!is_null($sSearchResult) && is_null($sNoHighlight) && $sString !=
"" )
122 $arr_string = explode(
" ", $sString );
123 if ( intval($sSearchResult) == 2 )
125 $arr_string[ 0 ] = str_replace(
"_",
" ", $arr_string[ 0 ] );
137 require PAGE_CONTENT;
page_content(int $block=1)