Skip to content

Orchard : Show complete post in blog list

By default, most of the Orchard themes (including the default Theme Machine) shows first couple of sentences with a link ‘more’ to read the entire content. In the latest version of Orchard, the limit is 200 characters and after that a ‘more…’ link  is appended. Look at the example below:

Capture

I wanted to override this setting and show the complete post in the list. Currently, I show five latest posts on my homepage. I did the following:

  1.  Add a file with name ‘Parts.Common.Body.Summary.cshtml’ to your themes directory.
    Note : Though this feature can be centrally changed as well, but that would mean all the themes/blogs have the same setting. I would recommend to do it per theme basis.
  2.  With in this file, add the following line:
    @Model.Html

And that’s it. Your blog list will show complete content of your posts instead of trimming them down to certain characters.

Published inUncategorized

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *