Advertisement
caledoniaman

Untitled

Aug 6th, 2012
29
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.63 KB | None | 0 0
  1. <?php
  2. /*
  3. Template Name: News
  4. */
  5. ?>
  6. <?php get_header(); ?>
  7. </div><!-- header-area -->
  8. </div><!-- end rays -->
  9. </div><!-- end header-holder -->
  10. </div><!-- end header -->
  11.  
  12. <?php truethemes_before_main_hook();// action hook, see truethemes_framework/global/hooks.php ?>
  13.  
  14. <div id="main">
  15. <?php get_template_part('theme-template-part-tools','childtheme'); ?>
  16.  
  17. <div class="main-holder">
  18. <?php get_template_part('theme-template-part-subnav-left','childtheme'); ?>
  19.  
  20. <div id="content" class="content_sidebar content_right_sidebar">
  21. <h2>Latest News</h2>
  22. <?php
  23. $temp = $wp_query;
  24. $wp_query= null;
  25. $wp_query = new WP_Query();
  26. $wp_query->query('cat=1'.'&paged='.$paged);
  27. ?>
  28. <?php while ($wp_query->have_posts()) : $wp_query->the_post(); ?>
  29.     <div class="uvpostwrapper">
  30.         <div class="uvthumb">
  31.             <?php
  32.                 if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
  33.                 the_post_thumbnail();
  34.                 } else {
  35.                 ?><img src="/images/lozenge.jpg" /><?php
  36.                 }
  37.             ?>
  38.             </div>
  39.             <div class="uvexcerpt">
  40.                 <h3><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3>
  41.                 <?php the_excerpt(); ?>
  42.                
  43.             </div>
  44.             <div class="uvclear"></div>
  45.     </div>
  46.  
  47.    
  48. <?php endwhile; ?>
  49. <?php
  50.  
  51. if(function_exists('wp_pagenavi')) {
  52. wp_pagenavi();
  53. }else{
  54. //not using this function, just for theme check plugin requirement.
  55. //do not remove this..
  56. paginate_links();
  57. }
  58. $wp_query = null; $wp_query = $temp;
  59. ?>
  60. </div><!-- end content -->
  61.  
  62. <div id="sidebar">
  63. <?php generated_dynamic_sidebar(); ?>
  64. </div><!-- end sidebar -->
  65. </div><!-- end main-holder -->
  66. </div><!-- main-area -->
  67.  
  68. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement