If you want to see different type of image & size in different post then you may use following code-
< ?php if ($image = get_post_meta($post->ID, ‘slide’, true)) { ?>
<img width=”617″ height=”350″ src=”<?php echo $image; ?>” alt=”Image” />
< ?php } else { ?>
< ?php $image = get_post_meta($post->ID, ‘simg’, true) ; ?>
<img width=”80″ height=”70″ src=”<?php echo $image; ?>” alt=”Small Image” />
< ?php } ?>
I use this code to (www.hdcbd.com) so show small image in category view and single page use big image.
Tags: One more image in if else, one more image in if else loop, one more image in if else loop in single post





kredi karti borcu taksitlendirme…
this was a sheer entertaining read. i enjoyed it very much!|Thanks for this article! How in the world….
oto kiralama…
I feel that is a fascinating point,…
facebook…
WAw some blog! I am loving it*…..
………. great post.
[...] Images in if-else | Source and Code [...]
[...] Images in if-else | Source and Code var a2a_config = a2a_config || {}; a2a_config.linkname="Cool Aging Article images"; a2a_config.linkurl="http://Aging.booksharecentral.net/2010/Aging-article/cool-aging-article-images-21/"; [...]
[...] Images in if-else | Source and Code var a2a_config = a2a_config || {}; a2a_config.linkname="Cool History Books images"; a2a_config.linkurl="http://History.booksharecentral.net/2010/History-books/cool-history-books-images-39/"; [...]