I would like to display a custom field in my footer.php file, I've managed to display the custom field in the main page using the code below which I want, but I'd also like to show the custom field in the footer, which would result in the custom field value being displayed in all pages of my theme, which is my goal.
<?php global $wp_query; $postid = $wp_query->post->ID; echo get_post_meta($postid, 'Your-Custom-Field', true); wp_reset_query(); ?>
[Please post code snippets between backticks or use the code button.]
Is this possible? If anyone could provide me with a solution that would be brilliant.
Thanks in advance