Advertisement
Guest User

Untitled

a guest
Apr 23rd, 2010
226
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.21 KB | None | 0 0
  1. <?php get_header(); ?>
  2.  
  3. <div id="left">
  4.  
  5.     <span class="section-title">Latest Article</span><br /><br />
  6. <!--Latest Post Loop-->
  7.         <?php if (have_posts()) : ?>
  8.         <?php
  9.             query_posts('posts_per_page=1&cat=-3');
  10.             while (have_posts()) : the_post();
  11.                 $postimageurl = get_post_meta($post->ID, 'image', true);
  12.                 $hastag = get_post_meta($post->ID, 'featured_hashtag', true);
  13.         ?> 
  14.             <div id="latest" <?php post_class() ?> >
  15.            
  16.                 <div id="post-left">
  17.                     <a href="<?php the_permalink(); ?>" rel="bookmark"><img src="<?php echo $postimageurl; ?>" alt="<?php the_title(); ?>" /></a>
  18.                    
  19.                     <div class="post-over">
  20.                         <h2><a href="<?php the_permalink(); ?>" title="Read: <?php the_title(); ?> "><?php the_title(); ?></a></h2>
  21.                         <span class="author">by <?php the_author() ?></span>
  22.                     </div>
  23.                     <span class="hastag">
  24.                         # <?php echo $hastag; ?>
  25.                     </span>
  26.                 </div>
  27.                
  28.                 <div id="post-right">
  29.                     <?php
  30.                         digg_digg_twitter_generate('Normal','lalawag');
  31.                             echo "<br /><br />";
  32.                         digg_digg_generate('Normal');
  33.                             echo "<br /><br />";
  34.                         digg_digg_fbshare_generate('Normal');
  35.                     ?>
  36.                    
  37.                 </div>
  38.  
  39.                 <div style="clear:both;"></div>
  40.             <!--End Recent post div--> 
  41.             </div>
  42.         <?php endwhile; ?>
  43.         <?php endif; ?>
  44. <div id="popular">
  45.         <span class="section-title">Popular Articles</span><br /><br />
  46. <!--Pop. post loop-->  
  47. <?php if (have_posts()) : ?>
  48.         <?php
  49.             query_posts('posts_per_page=3&cat=3'); 
  50.             while (have_posts()) : the_post();
  51.                 $custom_image = get_post_meta($post->ID, 'image_square', true);
  52.                 $custom_title = get_post_meta($post->ID, 'featured_title', true);
  53.         ?>
  54.             <div class="pop-single">
  55.                 <a href="<?php the_permalink(); ?>" rel="bookmark"><img src="<?php echo $custom_image; ?>" width="50" height="50"  alt="<?php the_title(); ?>" /></a>
  56.                 <h4><a href="<?php the_permalink(); ?>" title="Read Popular Article: <?php the_title(); ?>"><?php echo $custom_title; ?></a></h4>
  57.             </div>
  58.         <?php endwhile; ?>   
  59.             <div style="clear:both;"></div>
  60.     <!--End Popular Div--> 
  61. </div>
  62. <?php endif; ?>
  63. <div id="recent">
  64.         <span class="section-title">Recent Articles</span><br /><br />
  65. <!--Recent Post loop-->
  66.     <?php if (have_posts()) : ?>
  67.         <?php
  68.             query_posts('cat=-3&offset=1');
  69.             while (have_posts()) : the_post();
  70.                 $squareimage = get_post_meta($post->ID, 'image_square', true);
  71.         ?> 
  72.             <div class="single">
  73.                 <a href="<?php the_permalink(); ?>"><img src="<?php echo $squareimage; ?>" width="100" height="100" alt="<?php the_title(); ?>"/></a>
  74.                 <div class="single-content">
  75.                     <h2><a href="<?php the_permalink(); ?>" title="Read: <?php the_title(); ?>"><?php the_title(); ?></a></h2><br /><br />
  76.                     by <?php the_author() ?> / <?php the_date(); ?> / <?php comments_popup_link('No Comments', '1 Comment', '% Comments'); ?>
  77.                 </div>
  78.                 <div style="clear:both;"></div>
  79.             </div> 
  80.             <?php endwhile; ?>
  81.         <div class="navigation">
  82.             <div class="alignleft"><?php next_posts_link('&laquo; Older Entries') ?></div>
  83.             <div class="alignright"><?php previous_posts_link('Newer Entries &raquo;') ?></div>
  84.         </div>
  85.         <?php endif; ?>
  86. </div>
  87. <!--Dont Edit Below-->     
  88. </div>
  89. <?php get_sidebar(); ?>
  90. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement