Categories: Tutorials

How to display the Read More tag in excerpts on a category page in WordPress

The More tag is a link at the bottom of an article’s excerpt. It’s very useful when you want to short teasers (excerpts) of articles on your blog combined with a link to the full article.

Normally, the More tag only works on the homepage. The code is already in place, and you simply add in the post where you want the cut made.
There are various tricks out there that will allow you to do the same on a Page, and even on a category overview page. Here are a few examples:

Explaining the More tag:
http://codex.wordpress.org/Customizing_the_Read_More and
http://en.support.wordpress.com/splitting-content/more-tag/

Solutions:
rlmseo.com
wordpress.org: more tag not working in category display
wordpress.stackexchange.com
wordpress.org: read more link leads nowhere on page
weblogtoolscollection.com

My challenge was getting it to show on a category index page, where a list of post excerpts where shown.

For some reason (possibly because in my case I had to make it work on an older theme that may not have been built for it), none of these solutions worked. So I decided to create my own solution. It’s very simple, but I’ll post it here because I’m clearly not the only one who had this problem.

I started with this code in the category.php template:

blank
<div class="entry">
    <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"> <?php the_title(); ?></a>
    <?php the_excerpt(); ?>
    <p><small><?php  the_author(); ?>, <?php the_time('j F Y') ?></small></p>
</div>

And simply changed it to this:

<div class="entry">
    <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"> <?php the_title(); ?></a>
    <?php the_excerpt(); ?><em><a href="<?php the_permalink() ?>" rel="bookmark" title="Link to full article"><br/>Read more...</a></em>
    <p><small><?php  the_author(); ?>, <?php the_time('j F Y') ?></small></p>
</div>

If this works for you, please leave a comment, good luck!

This post was last modified on 26/06/2018 10:41

Boris Hoekmeijer

View Comments

  • I simply wanted to write down a quick word to say thanks to you for those wonderful tips and hints you are showing on this site.

  • (Thanks a lot very much for the high quality and results-oriented help. I won’t think twice to endorse your blog post to anybody who wants and needs support about this area.

  • I have recently started a web site, the information you provide on this site has helped me tremendously. Thank you for all of your time & work.

  • Needed to compose you a very little word to thank you yet again regarding the nice suggestions you’ve contributed here.

  • I appreciate, cause I found just what I was looking for. You have ended my 4 day long hunt! God Bless you man. Have a nice day. Bye

  • Hey there, You've done an excellent job. I'll definitely digg it and personally
    recommend to my friends. I am confident they will be benefited from this site.

  • Quality articles or reviews is the main to interest the users to
    go to see the website, that's what this web site is providing.

  • Incredible! Wonderful step by step guide. I'm about to employ that!

  • As a Newbie, I am constantly exploring online for articles that can help me. Thank you

Share
Published by
Boris Hoekmeijer

Recent Posts

Agribusiness Service

Website en logo ontwerp voor Kookstudio Aalsmeer - voor uw kookclub, kookfeest of bedrijfsuitje in…

4 months ago

CardioThoracaal Chirurgie Zorgpad

Website en logo ontwerp voor Kookstudio Aalsmeer - voor uw kookclub, kookfeest of bedrijfsuitje in…

4 months ago

7huijzen Food Quality & Innovation Management

Website en logo ontwerp voor Kookstudio Aalsmeer - voor uw kookclub, kookfeest of bedrijfsuitje in…

6 months ago

Prime Housing

Website en logo ontwerp voor Kookstudio Aalsmeer - voor uw kookclub, kookfeest of bedrijfsuitje in…

6 months ago

Cor de Kroon

Website en logo ontwerp voor Kookstudio Aalsmeer - voor uw kookclub, kookfeest of bedrijfsuitje in…

8 months ago

Hoe leeg je de cache van je browser?

Building your WordPress website efficiently using the 10 tips I documented after years of experience.…

1 year ago