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're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Archive /

Our old forums are still available as a read-only archive.

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

Add comments to custom templates


Go to End


4 Posts   3251 Views

Avatar
lusiton

13 Posts

8 November 2007 at 4:20am

Edited: 08/11/2007 4:21am

Hi.
I'm creating a website from scratch www.myfriendsru.com/mysite/site/home and building a custom template for it. I can't figure out the way to add comments to some of the pages. I enabled comments on the back end but I guess I need correct divs and classes. Is there a way to find out more about how to do it. Thank you in advance.

Avatar
Andante

Community Member, 231 Posts

8 November 2007 at 9:59am

You need to add $PageComments to your template.

Avatar
lusiton

13 Posts

8 November 2007 at 10:11am

Thank you for replaying to my post earlier. I tried to put it in with the back end option by editing HTML and also I tried to put it in the content section on my template. No luck unfortunately.
Is ther any other code that I have to insert along with $PageComments ?

Thank you

Avatar
Andante

Community Member, 231 Posts

8 November 2007 at 1:56pm

No, it just needs to go in your template, and you need to have the allow comments box ticked in the CMS. Make sure you flush your templates (?flush=1).