Advertisement
alchymyth

post with thumb only

May 5th, 2012
309
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.08 KB | None | 0 0
  1. <h2 class="pagetitle">Suchergebnisse</h2>
  2. <?php while (have_posts()) : the_post(); ?>
  3. <?php if ( has_post_thumbnail() ) { //start of conditional section to show only for posts with thumbnail// ?>
  4. <div <?php post_class('post') ?>>
  5. <?php the_post_thumbnail(array(260,200), array("class" => "alignleft post_thumbnail")); ?>
  6. <h2 class="title" id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
  7. <div class="postdate"><img src="<?php bloginfo('template_url'); ?>/images/date.png" /> <?php the_time('F jS, Y') ?> <?php if (current_user_can('edit_post', $post->ID)) { ?> <img src="<?php bloginfo('template_url'); ?>/images/edit.png" /> <?php edit_post_link('Edit', '', ''); } ?></div>
  8. <div class="entry">
  9. <?php the_excerpt() ?>
  10. </div>
  11. <div class="readmorecontent">
  12. <a class="readmore" href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">Zum Artikel ยป</a>
  13. </div>
  14. </div>
  15. <?php } //end of conditional section// ?>
  16. <?php endwhile; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement