I have a custom field called XYZ with url and I need to put that url in theme template (footer), outside the loop - like this: <a href="XYZ value">some example text</a>
When I call this custom field:
<a href="<?php echo get_post_meta($post->ID, 'XYZ', true); ?>">some example text</a>
it just shows <a href="current posts permalink">some example text</a>
So how to do that properly?
