/b2evolution/pixel/posts.main.php

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