WP Nivo Slider display the image title as caption.
Is there a way of using the post title as caption? I tried to use attributes in the_post_thumbnail(), but it requires me to override the image size and that just broke the plugin.
The code I tried:
<?php if(has_post_thumbnail()) : ?> <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"> <?php the_post_thumbnail(array(w,h), array ('title' => trim(strip_tags( $attachment->post_title )),); ?> </a> <?php endif ?>
Thanks for the help with this awesome plugin!