Display WordPress custom fields outside the loop

Below is an idea for showing WordPress custom fields outside the loop. In normal case custom fields are called within loop. You may try to expand your work with the possibilities of below code. Hope this will useful in some particular kind of work.

	global $wp_query;
	$postid = $wp_query->post->ID;
	echo get_post_meta($postid, 'Your-Custom-Field', true);

You may find more details of above code at WordPress

Related posts:

HTML5 page structure

HTML5 offers more powerful structure comparing to older versions of Html. There are many new …

Partner with Us

We are providing an exclusive partnership offer to individuals and companies who are interested in setting up their own web design & development company. For more information about how to partner with us, please contact us