Jump to:

1851 Posts in 1606 Topics by 561 members

Blog Module

SilverStripe Forums » Blog Module » [Solved] Adding "Read more" at the end of the summary

Discuss the Blog Module.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1053 Views
  • JensR
    Avatar
    Community Member
    8 Posts

    [Solved] Adding "Read more" at the end of the summary Link to this post

    Hi everyone,

    I would like to add the text [read more] as a link to the complete post at the end of the summary (first paragraph) on the main blog page.

    Since I know nearly nothing about scripting, I thought I'd ask if someone here has a bit of code that I just can paste in.

    Thanks in advance,

    Jens

  • Double-A-Ron
    Avatar
    Community Member
    604 Posts

    Re: [Solved] Adding "Read more" at the end of the summary Link to this post

    Hi Mate,

    In /blog/templates/Includes/BlogSummary.ss you will see the standard link there at the bottom:

    <a href="$Link" class="readmore" title="Read Full Post">Read the full post</a>

    Either duplicate this code and add your own text, or simply edit the "Read the full post" text between the <a> tags.

    Aaron

  • JensR
    Avatar
    Community Member
    8 Posts

    Re: [Solved] Adding "Read more" at the end of the summary Link to this post

    Aaron, thanks for your quick answer.

    The solution was a lot simpler than this: I found out that the BlogSummary code was correct, but the reference had a type in it...

    1053 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.