Advertisement
Guest User

Untitled

a guest
Oct 17th, 2012
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.82 KB | None | 0 0
  1. <?php
  2. /*
  3. Template Name: Blog
  4. */
  5. get_header(); ?>
  6.  
  7. <?php if ( ! have_posts() ) : ?>
  8.             <h1>OH NOES.. NO POSTS!</h1>
  9.             <p>Apologies, but no results were found for the requested archive. Perhaps searching        will help find a related post.</p>
  10. <?php endif; ?>
  11.  
  12. <?php while ( have_posts() ) : the_post(); ?>
  13.  
  14. <tr>
  15.     <td >
  16.     <table width="1003" align="center" cellpadding="0" cellspacing="0">
  17.           <tr>
  18.             <td valign="top" class="bodybg"><table width="100%" cellspacing="0" cellpadding="0">
  19.           <tr>
  20.             <td valign="top" class="welcome" style="padding:9px 19px 20px 27px;">
  21.         <tr> <!-- start divs -->
  22.             <td>
  23.  
  24.     /* HERE is where I started the post titles and content */
  25.     <div id="content">
  26.             <h1><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h1>
  27.                     <td>
  28.                         <div class="post-details">
  29.                             <td>
  30.                                 <div class="post-details-left">
  31.                                     Posted on <strong><?php echo get_the_date(); ?></strong> by <span class="author"><?php the_author(); ?></span> under <span class="category"><?php the_category(', '); ?></span>
  32.                                  </div>
  33.                             </td>
  34.                        
  35.             <td>
  36.                 <div class="post-details-right">
  37.                     <?php edit_post_link('Edit', '<span class="comment-count">  ' , '</span>'); ?><span class="comment-count"><?php comments_popup_link('Leave a comment', '1 Comment', '% Comments'); ?></span>
  38.                 </div>
  39.             </td>
  40.                            
  41.     </div>
  42.                     </td>
  43.        
  44.     /* Archive Excerpt Code */
  45.     <?php if ( is_archive() || is_search() ) : //display excerpts for archives and search. ?>
  46.                                     <?php the_excerpt(); ?>
  47.                             <?php else : ?>
  48.                                     <?php the_content('Read More'); ?>
  49.                             <?php endif; ?>
  50.  
  51.                
  52.                 </div><!-- end divs -->
  53.             </td>
  54.         </tr>      
  55.          </tr>
  56.         </table></td>
  57.       </tr>
  58.      
  59.       <!-- END BODY -->
  60.  
  61. <?php endwhile; ?>
  62.  
  63. <?php get_footer() ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement