Advertisement
Guest User

Untitled

a guest
Feb 23rd, 2013
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.01 KB | None | 0 0
  1. <?php get_header(); ?>
  2.  
  3. <?php
  4. $options = get_option('sf_supreme_options');
  5. $page_layout = $options['page_layout'];
  6. if (isset($_GET['layout'])) {
  7. $page_layout = $_GET['layout'];
  8. }
  9.  
  10. $show_page_title = get_post_meta($post->ID, 'sf_page_title', true);
  11. $top_spacing = get_post_meta($post->ID, 'sf_top_spacing', true);
  12. $spacing = "";
  13. if ($top_spacing) {
  14. $spacing = "top-spacing";
  15. } else {
  16. $spacing = "";
  17. }
  18. $sidebar_config = get_post_meta($post->ID, 'sf_sidebar_config', true);
  19. $left_sidebar = get_post_meta($post->ID, 'sf_left_sidebar', true);
  20. $right_sidebar = get_post_meta($post->ID, 'sf_right_sidebar', true);
  21. $page_wrap_class = '';
  22. if ($sidebar_config == "left-sidebar") {
  23. $page_wrap_class = 'has-left-sidebar has-one-sidebar';
  24. } elseif ($sidebar_config == "right-sidebar") {
  25. $page_wrap_class = 'has-right-sidebar has-one-sidebar';
  26. } elseif ($sidebar_config == "both-sidebars") {
  27. $page_wrap_class = 'has-both-sidebars';
  28. } else {
  29. $page_wrap_class = 'has-no-sidebar';
  30. }
  31. ?>
  32.  
  33. <?php if ($show_page_title) { ?>
  34.  
  35. <div class="page-heading clearfix">
  36.  
  37. <h2><?php the_title(); ?></h2>
  38.  
  39. <?php if(function_exists('bcn_display')) { ?>
  40. <div class="breadcrumbs-wrap">
  41. <div id="breadcrumbs">
  42. <?php bcn_display(); ?>
  43. </div>
  44. </div>
  45. <?php } ?>
  46.  
  47. <div class="heading-divider"></div>
  48.  
  49. </div>
  50. <?php } ?>
  51.  
  52. <div class="inner-page-wrap <?php echo $page_wrap_class; ?> clearfix">
  53.  
  54. <?php if (have_posts()) : the_post(); ?>
  55.  
  56. <!-- OPEN article -->
  57. <?php if ($sidebar_config == "left-sidebar") { ?>
  58. <div <?php post_class('clearfix two-thirds column omega '. $spacing); ?> id="<?php the_ID(); ?>">
  59. <?php } elseif ($sidebar_config == "right-sidebar") { ?>
  60. <div <?php post_class('clearfix two-thirds column alpha '. $spacing); ?> id="<?php the_ID(); ?>">
  61. <?php } else { ?>
  62. <div <?php post_class('clearfix '. $spacing); ?> id="<?php the_ID(); ?>">
  63. <?php } ?>
  64.  
  65. <?php if ($sidebar_config == "both-sidebars") { ?>
  66.  
  67. <section class="page-content eight columns omega clearfix">
  68.  
  69. <?php the_content(); ?>
  70.  
  71. </section>
  72.  
  73. <aside class="sidebar left-sidebar four columns alpha">
  74. <?php dynamic_sidebar($left_sidebar); ?>
  75. </aside>
  76.  
  77. <?php } else { ?>
  78.  
  79. <section class="page-content clearfix">
  80.  
  81. <?php the_content(); ?>
  82.  
  83. </section>
  84.  
  85. <?php } ?>
  86.  
  87. <!-- CLOSE article -->
  88. </div>
  89.  
  90. <?php endif; ?>
  91.  
  92. <?php if ($sidebar_config == "left-sidebar") { ?>
  93.  
  94. <aside class="sidebar left-sidebar one-third column alpha">
  95. <?php dynamic_sidebar($left_sidebar); ?>
  96. </aside>
  97.  
  98. <?php } else if ($sidebar_config == "right-sidebar") { ?>
  99.  
  100. <aside class="sidebar right-sidebar one-third column omega">
  101. <?php dynamic_sidebar($right_sidebar); ?>
  102. </aside>
  103.  
  104. <?php } else if ($sidebar_config == "both-sidebars") { ?>
  105.  
  106. <aside class="sidebar right-sidebar four columns omega">
  107. <?php dynamic_sidebar($right_sidebar); ?>
  108. </aside>
  109.  
  110. <?php } ?>
  111.  
  112. </div>
  113.  
  114. <!-- WordPress Hook -->
  115. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement