if custom field then print else don’t print
-
Hi All,
I’ve searched on this one and can find nothing. Any help would be gratefully appreciatedI’ve this code to get a image from a custom field
<?php $values = get_post_custom_values("miniatura"); if (isset($values[0])) { ?> <a href="<?php the_permalink() ?>" rel="bookmark" title="link permanente para <?php the_title(); ?>"><img src="<?php bloginfo('template_url'); ?>/miniatura/<?php $values = get_post_custom_values("miniatura"); echo $values[0]; ?>" alt="" /></a> <?php } ?>
and this works fine. The post load the image and the css.
The problem!? How can I make the post print the image and the css only if there is a custom field?
Can someone help me??
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘if custom field then print else don’t print’ is closed to new replies.