Skip to content
This repository has been archived by the owner on Aug 26, 2022. It is now read-only.

Commit

Permalink
Add caption support to featured posts.
Browse files Browse the repository at this point in the history
  • Loading branch information
mindctrl committed Oct 7, 2013
1 parent d57bf52 commit 4a4bf60
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions alienship-shortcodes.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ function alienship_featured_posts_shortcode( $atts, $content = null ) {
'width' => '850',
'height' => '350',
'indicators' => 'true',
'captions' => 'true',
), $atts )
);

Expand Down Expand Up @@ -191,9 +192,12 @@ function alienship_featured_posts_shortcode( $atts, $content = null ) {
<a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
<?php echo get_the_post_thumbnail( ''. $featured_query_shortcode->post->ID .'', array( $width, $height ), array( 'title' => "" ) ); ?>
</a>

<?php if ( 'true' == $captions ) { ?>
<div class="carousel-caption">
<h3><?php the_title(); ?></h3>
</div>
<?php } ?>
</div><!-- .item -->
<?php endwhile; ?>

Expand Down

0 comments on commit 4a4bf60

Please sign in to comment.