Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * @package Wordspop
- * @subpackage Fotofolio_Landscape
- */
- add_theme_support('webfont');
- /**
- * Load initial WPop script
- */
- require_once dirname(__FILE__) . '/libs/wpop/init.php';
- function the_post_thumbnail_caption() {
- global $post;
- $thumb_id = get_post_thumbnail_id($post->id);
- $args = array(
- 'post_type' => 'attachment',
- 'post_status' => null,
- 'post_parent' => $post->ID,
- 'include' => $thumb_id
- );
- $thumbnail_image = get_posts($args);
- if ($thumbnail_image && isset($thumbnail_image[0])) {
- //show thumbnail title
- echo $thumbnail_image[0]->post_title;
- //Uncomment to show the thumbnail caption
- //echo $thumbnail_image[0]->post_excerpt;
- //Uncomment to show the thumbnail description
- //echo $thumbnail_image[0]->post_content;
- //Uncomment to show the thumbnail alt field
- //$alt = get_post_meta($thumbnail_id, '_wp_attachment_image_alt', true);
- //if(count($alt)) echo $alt;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement