Custom Field – Thumbnails
-
Hi
currently code i use for my custom field (thumbnail) is
<?php if(get_post_meta($post->ID, "thumbnail", true)) { $size = getimagesize($_SERVER[""].get_post_meta($post->ID, "thumbnail", true)); ?> <img src="<?php echo get_post_meta($post->ID, "thumbnail", true); ?>" alt="<?php the_title(); ?>" width="<?php echo $size[0]; ?>" height="<?php echo $size[1]; ?>" /> <?php } ?>
Question here. How to make it will appear No Thumbnail Image if we not fill the input on custom field?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Custom Field – Thumbnails’ is closed to new replies.