trumpet1981
Member
Posted 1 year ago #
Hi,
I have created an image field called image01. I tried to display the image in my post and i include the following line to the post template.
<?php echo get_post_meta_image($post->ID, "image01", true); ?>
However, the display is the URL of the image. How can I display image?
Thanks!
valerama
Member
Posted 1 year ago #
How you call a meta field depends partly on your theme. Please provide more info.
joetheboss
Member
Posted 1 year ago #
The correct syntax is:
<img src="<?php echo get_post_meta($post->ID, 'image01', true); ?>" />