PageRenderTime 563ms CodeModel.GetById 248ms app.highlight 31ms RepoModel.GetById 264ms app.codeStats 12ms

/b2evolution/emerald/posts.main.php

http://laibcomsthemes.googlecode.com/
PHP | 144 lines | 74 code | 20 blank | 50 comment | 3 complexity | 68122cf46e4ff6cac795d45e7991df89 MD5 | raw file
  1<?php
  2/**
  3 * This is the main/default page template.
  4 *
  5 * For a quick explanation of b2evo 2.0 skins, please start here:
  6 * {@link http://manual.b2evolution.net/Skins_2.0}
  7 *
  8 * The main page template is used to display the blog when no specific page template is available
  9 * to handle the request (based on $disp).
 10 *
 11 * @package evoskins
 12 * @subpackage emerald
 13 *
 14 * @version $Id: posts.main.php,v 1.10 2009/01/21 20:33:49 fplanque Exp $
 15 */
 16if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
 17
 18if( version_compare( $app_version, '3.3' ) < 0 )
 19{ // Older skins (versions 2.x and above) should work on newer b2evo versions, but newer skins may not work on older b2evo versions.
 20	die( 'This skin is designed for b2evolution 3.3 and above. Please <a href="http://b2evolution.net/downloads/index.html">upgrade your b2evolution</a>.' );
 21}
 22
 23// This is the main template; it may be used to display very different things.
 24// Do inits depending on current $disp:
 25skin_init( $disp );
 26
 27
 28// -------------------------- HTML HEADER INCLUDED HERE --------------------------
 29skin_include( '_html_header.inc.php' );
 30// Note: You can customize the default HTML header by copying the generic
 31// /skins/_html_header.inc.php file into the current skin folder.
 32// -------------------------------- END OF HEADER --------------------------------
 33?>
 34
 35
 36<?php
 37// ------------------------- BODY HEADER INCLUDED HERE --------------------------
 38skin_include( '_body_header.inc.php' );
 39// Note: You can customize the default BODY header by copying the generic
 40// /skins/_body_footer.inc.php file into the current skin folder.
 41// ------------------------------- END OF HEADER --------------------------------
 42?>
 43
 44<div id="content">
 45	<div id="primaryContentContainer">
 46		<div id="primaryContent">
 47
 48			<?php
 49				// ------------------------- TITLE FOR THE CURRENT REQUEST -------------------------
 50				request_title( array(
 51						'title_before'=> '<h2 class="sectionhead">',
 52						'title_after' => '</h2>',
 53						'title_none'  => '',
 54						'glue'        => ' - ',
 55						'title_single_disp' => true,
 56						'format'      => 'htmlbody',
 57					) );
 58				// ------------------------------ END OF REQUEST TITLE -----------------------------
 59			?>
 60
 61
 62			<?php
 63				// ------------------------- MESSAGES GENERATED FROM ACTIONS -------------------------
 64				messages( array(
 65					'block_start' => '<div class="action_messages">',
 66					'block_end'   => '</div> <!-- end of class="action_messages" -->',
 67				) );
 68				// --------------------------------- END OF MESSAGES ---------------------------------
 69			?>
 70
 71			<?php
 72			// Go Grab the featured post:
 73			if( $Item = & get_featured_Item() )
 74			{	// We have a featured/intro post to display:
 75				// ---------------------- ITEM BLOCK INCLUDED HERE ------------------------
 76				skin_include( '_item_block.inc.php', array(
 77						'feature_block' => true,
 78						'content_mode' => 'auto',		// 'auto' will auto select depending on $disp-detail
 79						'intro_mode'   => 'normal',	// Intro posts will be displayed in normal mode
 80						'item_class'   => 'featurepost',
 81						'image_size'	 =>	'fit-400x320',
 82					) );
 83				// ----------------------------END ITEM BLOCK  ----------------------------
 84			}
 85			?>
 86
 87				<div class="space"></div>
 88
 89			<?php
 90				// Display message if no post:
 91				display_if_empty();
 92		
 93				while( $Item = & mainlist_get_item() )
 94				{	// For each blog post:
 95					// ---------------------- ITEM BLOCK INCLUDED HERE ------------------------
 96					skin_include( '_item_block.inc.php', array(
 97							'content_mode' => 'auto',		// 'auto' will auto select depending on $disp-detail
 98							'image_size'	 =>	'fit-400x320',
 99						) );
100					// Note: You can customize the default item feedback by copying the generic
101					// /skins/_item_feedback.inc.php file into the current skin folder.
102					// ----------------------------END ITEM BLOCK  ----------------------------
103				}
104			?>
105		
106			<?php
107				// -------------------- PREV/NEXT PAGE LINKS (POST LIST MODE) --------------------
108				mainlist_page_links( array(
109						'block_start' => '<div id="navigation">',
110						'block_end' => '</div> <!-- end of id="navigation" -->',
111						'prev_text' => '<span class="older">&#171;</span>',
112						'next_text' => '<span class="newer">&#187;</span>',
113					) );
114				// ------------------------- END OF PREV/NEXT PAGE LINKS -------------------------
115			?>
116
117			</div> <!-- end of id="primaryContent" -->
118		</div> <!-- end of id="primaryContentContainer" -->
119
120<?php
121// ------------------------- SIDEBAR INCLUDED HERE --------------------------
122skin_include( '_sidebar_right.inc.php' );
123// Note: You can customize the default BODY footer by copying the
124// _body_footer.inc.php file into the current skin folder.
125// ----------------------------- END OF SIDEBAR -----------------------------
126?>
127
128	</div> <!-- end of id="content" -->
129
130<?php
131// ------------------------- BODY FOOTER INCLUDED HERE --------------------------
132skin_include( '_body_footer.inc.php' );
133// Note: You can customize the default BODY footer by copying the
134// _body_footer.inc.php file into the current skin folder.
135// ------------------------------- END OF FOOTER --------------------------------
136?>
137
138<?php
139// ------------------------- HTML FOOTER INCLUDED HERE --------------------------
140skin_include( '_html_footer.inc.php' );
141// Note: You can customize the default HTML footer by copying the
142// _html_footer.inc.php file into the current skin folder.
143// ------------------------------- END OF FOOTER --------------------------------
144?>