Wordpress !–more– tag not showing or working
by Isaac.NG - September 15th, 2009
If you do lots of customisation hacks on your wordpress theme, such as using query_posts(‘..’) with loads of funny stuff, you might find later down the road that the ‘more’ tag is not working for your blog.
To confirm that this is a theme issue, switch to WP’s default theme temporarily and see if the more tag is shown. If the tag still doesn’t show, it should be a plug-in issue which is not discussed in this post.
So how do I fix it if its my theme?
Check this codex snippet:
http://codex.wordpress.org/Template_Tags/query_posts#Retrieve_a_Particular_Post
If you want to use the Read More functionality with this query, you will need to set the global $more variable to 0.
<?php
global $more;
// set $more to 0 in order to only get the first part of the post
$more = 0;
?>
Took me awhile figure out, hopefully this will help you!
No related posts.






Subscribe to our feed!