Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

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

Displaying comments count on BlogHolder


Go to End


1513 Views

Avatar
Groundnation

Community Member, 1 Post

12 November 2013 at 6:01am

Would really appreciate any help with this - I want the comments count displayed on the BlogHolder. I'm using SS3.1 with the comments module but when adding $Comments.Count to the template I get this error;

[User Error] Uncaught Exception: No has_one found on class 'Comment', the has_many relation from 'BlogEntry' to 'Comment' requires a has_one on 'Comment'

What am I missing??