Advertisement
Guest User

Gallery page template

a guest
Feb 6th, 2014
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.10 KB | None | 0 0
  1. <?php
  2.  
  3. /* Template Name: Galeria
  4.  
  5. */
  6.  
  7. $option =  get_option('scl_options'); ?>
  8.  
  9. <?php get_header(); ?>
  10.  
  11.  
  12.  
  13. <div id="content">
  14.  
  15.         <!--Slider-->
  16.  
  17.         <div id="slide_wrap">
  18.  
  19.         <?php if($option["scl_diss_rbn"] == "1"){ ?><?php } else { ?><div class="ribbon"><?php echo $option['scl_rbn_txt'] ?></div><?php } ?>
  20.  
  21.         <?php if($option['scl_slider']== "Easyslider") { ?>
  22.  
  23.         <?php get_template_part('easyslider'); ?>
  24.  
  25.         <?php }?>
  26.  
  27.         </div>
  28.  
  29.  
  30.  
  31.        
  32.  
  33.         <!--POSTS-->
  34.  
  35.         <div id="posts">
  36.  
  37.        
  38.  
  39.             <div id="lay1">
  40.  
  41.             <?php if(have_posts()): while(have_posts()): the_post(); ?>
  42.  
  43.                 <div <?php post_class(); ?> id="post-<?php the_ID(); ?>">
  44.  
  45.                
  46.  
  47.             <!--THE Date Badge-->    
  48.  
  49.             <?php if($option["scl_diss_date"] == "1"){ ?>
  50.  
  51.             <?php } else { ?>
  52.  
  53.  
  54.  
  55.             <div class="date"><div class="date_content"><?php the_time('dS'); ?> <?php the_time('M'); ?><span><?php the_time('Y'); ?></span></div></div>       
  56.  
  57.             <?php }?>
  58.  
  59.                
  60.  
  61.                 <div class="post_image">
  62.  
  63.                      <!--CALL TO POST IMAGE-->
  64.  
  65.                     <?php if ( has_post_thumbnail() ) : ?>
  66.  
  67.                     <div class="imgwrap"><a href="<?php the_permalink();?>"><?php the_post_thumbnail('medium'); ?></a></div>
  68.  
  69.                    
  70.  
  71.                     <?php elseif($photo = scl_get_images('numberposts=1', true)): ?>
  72.  
  73.    
  74.  
  75.                     <div class="imgwrap">
  76.  
  77.                     <a href="<?php the_permalink();?>"><?php echo wp_get_attachment_image($photo[0]->ID ,'medium'); ?></a></div>
  78.  
  79.                
  80.  
  81.                     <?php else : ?>
  82.  
  83.                    
  84.  
  85.                     <div class="imgwrap"><a href="<?php the_permalink();?>"><img src="<?php echo get_template_directory_uri(); ?>/images/blank_img.png" alt="<?php the_title_attribute(); ?>" class="thumbnail"/></a></div>  
  86.  
  87.                              
  88.  
  89.                     <?php endif; ?>
  90.  
  91.  
  92.  
  93.                 </div>
  94.  
  95.                
  96.  
  97.                
  98.  
  99.                 <div class="post_content">
  100.  
  101.                     <h2 class="postitle"><a href="<?php the_permalink();?>" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
  102.  
  103.                     <?php scl_excerpt('scl_excerptlength_teaser', 'scl_excerptmore'); ?>
  104.  
  105.                 </div>
  106.  
  107.                
  108.  
  109.                 <div class="post_meta"><div class="block_comm"><?php if (!empty($post->post_password)) { ?>
  110.  
  111.             <?php } else { ?><div class="comments"><?php comments_popup_link('0 <span>Comm</span>', '1 <span>Comm</span>', '% <span>Comm</span>', '', __('Off')); ?></div><?php } ?></div></div>
  112.  
  113.                
  114.  
  115.                 </div>
  116.  
  117.                
  118.  
  119.              <?php endwhile ?>
  120.  
  121.             <?php if (function_exists("scylla_paginate")) {
  122.  
  123.                 scylla_paginate();
  124.  
  125.                  } ?>  
  126.  
  127.             <?php endif ?>
  128.  
  129.             </div>
  130.  
  131.            
  132.  
  133.         </div>
  134.  
  135. </div>
  136.  
  137.  
  138.  
  139.     <!--Sidebar-->
  140.  
  141. <?php get_sidebar(); ?>
  142.  
  143. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement