Custom field outside the loop
<?php
global $wp_query;
$postid = $wp_query->post->ID;
echo get_post_meta($postid, 'customField', true);
?>
Instructions:
Display your custom field outside the loop.
<?php
global $wp_query;
$postid = $wp_query->post->ID;
echo get_post_meta($postid, 'customField', true);
?>
Display your custom field outside the loop.
If you like this snippet, share it with friends!