wp-caption problem – can it be used outside of the_content?
-
Hi all,
I have this code (below) that I am trying to use with wp-captions. But as far as I can see captions are only used in the_content. Is there a way of using outside?
<div class="wideImage"> <?php // Generates image for latest post $thumb = get_post_meta($post->ID, 'img-thumb', true); if ($thumb == '') { ?> <img src="<?php bloginfo('template_url'); ?>/scripts/timthumb.php?src=<?php echo c2c_random_file('/media/rotate/'); ?>&w=640&h=360&zc=1&" title="<?php the_title(); ?>" alt="<?php the_title(); ?>" /> <?php } else { ?> <img src="<?php bloginfo('template_url'); ?>/scripts/timthumb.php?src=<?php echo $thumb; ?>&w=640&h=360&zc=1&" title="<?php the_title(); ?>" alt="<?php the_title(); ?>"/> <?php } ?> </div><!-- end .wideImage -->
Thanks
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘wp-caption problem – can it be used outside of the_content?’ is closed to new replies.