Advertisement
Guest User

EvoLve Pro - 2-columns.php

a guest
Dec 28th, 2012
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.07 KB | None | 0 0
  1. <?php
  2. /**
  3. * Template Name: Two columns - one sidebar
  4. *
  5. * @package EvoLve
  6. * @subpackage Template
  7. */
  8. ?>
  9. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  10.  
  11. <!--BEGIN html-->
  12. <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
  13.  
  14.  
  15. <!--BEGIN head-->
  16. <head profile="<?php evlget_profile_uri(); ?>">
  17.  
  18. <title><?php wp_title('-', true); ?></title>
  19.  
  20. <!-- Meta Tags -->
  21. <meta http-equiv="Content-Type" content="<?php bloginfo( 'html_type' ); ?>; charset=<?php bloginfo('charset'); ?>" />
  22. <meta name="generator" content="WordPress" />
  23.  
  24. <?php wp_head(); ?>
  25.  
  26.  
  27. <style type="text/css">
  28. .hfeed {min-width: 610px;width: 64%;}
  29. .aside {min-width: 320px;width: 34%;}
  30. </style>
  31.  
  32. <!--END head-->
  33. </head>
  34.  
  35.  
  36.  
  37. <!--BEGIN body-->
  38. <body <?php body_class(); ?>>
  39.  
  40. <?php $options = get_option('evolve');if ($options['evl_custom_background'] == "1") { ?>
  41. <div id="wrapper">
  42. <?php } ?>
  43.  
  44. <div id="top"></div>
  45.  
  46.  
  47.  
  48. <!--BEGIN .header-->
  49. <div class="header" style="margin: 0 auto;<?php if( get_header_image() ) { ?>padding:10px 20px 35px 20px;width: 940px;background:url('<?php header_image(); ?>');<?php } ?>">
  50.  
  51. <?php $options = get_option('evolve');
  52. if ($options['evl_main_menu_pos'] == "before") { ?>
  53. <!--BEGIN .container-menu-->
  54. <div class="container" style="margin:0 auto;margin-top:40px;position:relative;z-index:99;">
  55.  
  56. <?php main_menu_pos(); ?>
  57.  
  58. </div> <?php } ?>
  59.  
  60. <!--BEGIN .container-->
  61. <div class="container" style="margin-bottom:0px;">
  62.  
  63.  
  64. <div class="radial-effect"></div>
  65.  
  66.  
  67.  
  68. <!-- AD Space 1 -->
  69.  
  70.  
  71.  
  72. <?php $options = get_option('evolve');
  73.  
  74. if (!empty($options['evl_ads_1_id'])) {
  75. $ads_slot = $options['evl_ads_1_id'];
  76. $adsize = $options['evl_ads_1'];
  77. echo '<div style="float:right;margin-left:10px;overflow:hidden;">'.adsense_unit($ads_slot,$adsize).'</div>';
  78. }
  79.  
  80. if (!empty($options['evl_space_1'])) {
  81. $ad_space_1 = $options['evl_space_1'];
  82. echo '<div style="float:right;margin-left:10px;overflow:hidden;">'.stripslashes($ad_space_1).'</div>';
  83. }
  84.  
  85. ?>
  86. <?php $options = get_option('evolve');
  87. if ($options['evl_search_field'] == "inside") { ?>
  88.  
  89. <!--BEGIN #righttopcolumn-->
  90. <div id="righttopcolumn">
  91.  
  92. <?php get_search_form(); ?>
  93.  
  94. </div>
  95. <!--END #righttopcolumn-->
  96.  
  97. <?php } ?>
  98.  
  99.  
  100.  
  101. <?php $options = get_option('evolve'); if ($options['evl_pos_logo'] == "disable") { ?>
  102.  
  103. <?php } else { ?>
  104.  
  105. <?php $options = get_option('evolve');
  106. if (!empty($options['evl_header_logo'])) {
  107. echo "<a href=".home_url()."><img id='logo-image' src=".$options['evl_header_logo']." /></a>";
  108. }
  109. ?>
  110.  
  111. <?php } ?>
  112.  
  113.  
  114. <?php
  115. $taglinestyle = '';
  116.  
  117. if (($options['evl_tagline_pos'] !== "disable") && ($options['evl_tagline_pos'] == "under")) {
  118. $taglinestyle = "style='clear:left;padding-top:10px;'";
  119. }
  120.  
  121. if (($options['evl_tagline_pos'] !== "disable") && ($options['evl_tagline_pos'] == "above")) {
  122. $taglinestyle = "style='padding-top:0px;'"; }
  123.  
  124. $tagline = '<div id="tagline" '.$taglinestyle.'>'.get_bloginfo( 'description' ).'</div>';
  125.  
  126. if (($options['evl_tagline_pos'] !== "disable") && ($options['evl_tagline_pos'] == "above")) {
  127. $taglinestyle = "padding-top:10px;'";
  128.  
  129. echo $tagline;
  130.  
  131. } ?>
  132.  
  133.  
  134. <?php if ($options['evl_blog_title'] == "1") { ?>
  135.  
  136. <?php } else { ?>
  137.  
  138.  
  139.  
  140. <div id="logo"><span></span><a href="<?php echo home_url(); ?>"><?php bloginfo( 'name' ) ?></a></div>
  141.  
  142. <?php } if (($options['evl_tagline_pos'] !== "disable") && (($options['evl_tagline_pos'] == "") || ($options['evl_tagline_pos'] == "next") || ($options['evl_tagline_pos'] == "under")))
  143. {
  144. echo $tagline;
  145.  
  146. } ?>
  147.  
  148. <!--END .container-->
  149. </div>
  150.  
  151. <!--END .header-->
  152. </div>
  153.  
  154.  
  155. <div class="menu-container">
  156.  
  157. <div class="menu-back">
  158.  
  159.  
  160.  
  161.  
  162.  
  163. <?php $options = get_option('evolve');
  164. if ($options['evl_main_menu_pos'] == "after" || $options['evl_main_menu_pos'] == "") { ?>
  165.  
  166.  
  167. <!--BEGIN .container-menu-->
  168. <div class="container nacked-menu" style="margin:0 auto;padding-bottom:10px;position:relative;z-index:9;">
  169.  
  170.  
  171. <?php main_menu_pos(); ?>
  172.  
  173. </div>
  174.  
  175.  
  176. <?php } else { } ?>
  177.  
  178.  
  179.  
  180. <?php $options = get_option('evolve');
  181. if ($options['evl_main_menu_pos'] == "before") { ?>
  182. <div style=";margin-bottom:30px;"></div> <?php } ?>
  183.  
  184.  
  185. <!--BEGIN header-content.php -->
  186.  
  187. <?php $options = get_option('evolve');
  188. if (is_home()) {
  189. $settings = $options['evl_home_header_content'];
  190. } elseif (is_single()) {
  191. $settings = $options['evl_single_header_content'];
  192. } else {
  193. $settings = $options['evl_archives_header_content']; }
  194.  
  195.  
  196. ?>
  197.  
  198. <?php get_template_part('header-content', 'header'); ?>
  199.  
  200.  
  201.  
  202. <!--END header-content.php -->
  203.  
  204.  
  205. <?php $options = get_option('evolve');
  206.  
  207. // if Header widgets exist
  208.  
  209. if (($options['evl_widgets_header'] == "") || ($options['evl_widgets_header'] == "disable"))
  210. { } else { ?>
  211.  
  212. <div class="container widgets-back" style="margin-top:0;margin-bottom:0;width:100%;">
  213.  
  214.  
  215. <!--BEGIN .widgets-holder-->
  216. <div class="widgets-holder widgets-back-inside" style="margin:20px auto 0 auto;">
  217.  
  218. <div class="header-1">
  219. <?php if ( !dynamic_sidebar( 'header-1' )) : ?>
  220. <?php endif; ?>
  221. </div>
  222.  
  223. <div class="header-2">
  224. <?php if ( !dynamic_sidebar( 'header-2' ) ) : ?>
  225. <?php endif; ?>
  226. </div>
  227.  
  228. <div class="header-3">
  229. <?php if ( !dynamic_sidebar( 'header-3' ) ) : ?>
  230. <?php endif; ?>
  231. </div>
  232.  
  233.  
  234. <div class="header-4">
  235. <?php if ( !dynamic_sidebar( 'header-4' ) ) : ?>
  236. <?php endif; ?>
  237. </div>
  238.  
  239. </div>
  240.  
  241. <!--END .widgets-holder-->
  242.  
  243. </div>
  244.  
  245.  
  246.  
  247. <?php } ?>
  248.  
  249. <!-- AD Space 2 -->
  250.  
  251.  
  252. <?php $options = get_option('evolve');
  253. if (!empty($options['evl_space_2'])) {
  254.  
  255. if (!empty($options['evl_ads_2_id'])) {
  256. $ads_slot = $options['evl_ads_2_id'];
  257. $adsize = $options['evl_ads_2'];
  258. echo '<div style="clear:both;text-align:center;margin:10px 0 15px 0;overflow:hidden;">'.adsense_unit($ads_slot,$adsize).'</div>';
  259. }
  260.  
  261. $ad_space_2 = $options['evl_space_2'];
  262. echo '<div style="clear:both;text-align:center;margin:10px 0 15px 0;overflow:hidden;">'.stripslashes($ad_space_2).'</div>';
  263.  
  264. }
  265. ?>
  266.  
  267.  
  268. </div>
  269. <?php if (is_home() && ($options['evl_bigslideshow_home'] == "1") ||
  270. is_single() && ($options['evl_bigslideshow_post'] == "1") ||
  271. (is_archive() || is_page()) && ($options['evl_bigslideshow_archives'] == "1")
  272. ) { ?>
  273.  
  274.  
  275. <div class="slider-wrapper theme-default" style="margin-top:0;">
  276. <div id="shadow-effect"></div>
  277. <div id="nivo_holder" class="nivoSlider">
  278.  
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285. <?php $postscategory = ''; if ($options['evl_slideshow_content'] == "posts_category" && !empty($options['evl_category_number']) ) { $postscategory = $options['evl_category_number']; }
  286. $postsnumber = $options['evl_posts_number'];
  287. ?>
  288.  
  289.  
  290. <?php
  291. $featured = "";
  292. $captions = array();
  293. $tmp = $featured;
  294. $args=array(
  295. 'cat'=> $postscategory,
  296. 'showposts'=> $postsnumber,
  297. 'ignore_sticky_posts' =>1,
  298. );
  299. query_posts($args);
  300. ?>
  301.  
  302.  
  303. <?php if (have_posts()) : $featured = new WP_Query($args); while($featured->have_posts()) : $featured->the_post();$captions[] = get_the_title($post->ID); ?>
  304.  
  305.  
  306.  
  307.  
  308. <?php $image = evlget_first_image();
  309. if ($image) { ?>
  310. <a href="<?php the_permalink() ?>"><img src="<?php echo $image; ?>" title="#caption<?php echo count($captions)-1; ?>" alt="<?php the_title_attribute(); ?>" /></a>
  311.  
  312. <?php } else { ?>
  313.  
  314. <a href="<?php the_permalink() ?>"><img src="<?php echo get_bloginfo( 'template_url' ); ?>/library/media/images/default.jpg" title="#caption<?php echo count($captions)-1; ?>" alt="<?php the_title_attribute(); ?>" /></a>
  315.  
  316. <?php } ?>
  317.  
  318. <?php endwhile; ?>
  319.  
  320. <?php else: ?>
  321.  
  322. <span>
  323. <?php _e( 'Oops, please check your slideshow settings', 'evolve' ); ?>
  324. </span>
  325.  
  326. <?php endif; $featured = $tmp; ?>
  327.  
  328.  
  329.  
  330.  
  331.  
  332. </div> <div id="nivo-control-bar"></div>
  333.  
  334.  
  335.  
  336. </div>
  337.  
  338. <!-- close #slider -->
  339. <?php
  340. foreach($captions as $key => $caption) :
  341. ?>
  342.  
  343. <div id="caption<?php echo $key; ?>" class="nivo-html-caption">
  344. <div class="ribbon"><?php $options = get_option('evolve');if ($options['evl_ribbon_text'] != "" ) { echo $options['evl_ribbon_text']; } else { echo 'Featured'; } ?></div><?php echo $caption; ?>
  345. </div>
  346. <?php
  347. endforeach;
  348. ?>
  349.  
  350. <?php wp_reset_query(); ?>
  351.  
  352.  
  353. <div style="clear:both;"></div> <?php } ?>
  354.  
  355. <!--BEGIN .content-->
  356. <div class="content <?php semantic_body(); ?>">
  357.  
  358.  
  359.  
  360.  
  361. <!--BEGIN .container-->
  362. <div class="container" style="margin:0px auto;">
  363.  
  364.  
  365.  
  366.  
  367. <!--BEGIN #content-->
  368. <div id="content">
  369.  
  370. <!--BEGIN #primary .hfeed-->
  371. <div id="primary" class="hfeed">
  372.  
  373.  
  374.  
  375.  
  376.  
  377. <?php if ( have_posts() ) : ?>
  378. <?php while ( have_posts() ) : the_post(); ?>
  379.  
  380. <!--BEGIN .hentry-->
  381. <div id="post-<?php the_ID(); ?>" class="<?php semantic_entries(); ?>">
  382. <h1 class="entry-title"><?php if ( get_the_title() ){ the_title(); }else{ _e( 'Untitled', 'evolve' ); } ?></h1>
  383.  
  384. <?php if ( current_user_can( 'edit_post', $post->ID ) ): ?>
  385.  
  386. <?php edit_post_link( __( 'EDIT', 'evolve' ), '<span class="edit-page">', '</span>' ); ?>
  387.  
  388.  
  389. <?php endif; ?>
  390.  
  391. <br /><br />
  392.  
  393. <!--BEGIN .entry-content .article-->
  394. <div class="entry-content article">
  395. <?php the_content( __('READ MORE &raquo;', 'evolve' ) ); ?>
  396. <!--END .entry-content .article-->
  397. <div style="clear:both;"></div>
  398. </div>
  399.  
  400.  
  401.  
  402. <!-- Auto Discovery Trackbacks
  403. <?php trackback_rdf(); ?>
  404. -->
  405. <!--END .hentry-->
  406. </div>
  407.  
  408. <?php $options = get_option('evolve'); if (($options['evl_share_this'] == "all")) {
  409. evolve_sharethis(); } ?>
  410.  
  411. <?php comments_template( '', true ); ?>
  412.  
  413. <?php endwhile; endif; ?>
  414.  
  415.  
  416.  
  417.  
  418.  
  419. <!--END #primary .hfeed-->
  420. </div>
  421.  
  422.  
  423. <?php get_sidebar(); ?>
  424.  
  425. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement