Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php if ( is_search() || is_home() || is_category() || is_archive() ) : // Display Excerpts for Search and Homepage ?>
- <div class="entry-summary">
- <!-- Conditional thumbnail for categories -->
- <div class="excerpt-thumb">
- <?php if ( (function_exists('has_post_thumbnail')) && (has_post_thumbnail())) : ?>
- <a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark">
- <?php the_post_thumbnail('excerpt-thumbnail', 'class=alignright'); ?>
- </a>
- <?php else :?>
- <a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark">
- <img class="alignright" src="<?php echo get_stylesheet_directory_uri(); ?>/images/<?php $category = get_the_category(); echo $category[0]->slug; ?>.png" />
- </a>
- <?php endif;?>
- </div>
- <?php the_excerpt(); ?>
- </div><!-- .entry-summary -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement