10382 Posts in 2196 Topics by 1711 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 424 Views |
-
$pageComments Question

2 April 2011 at 2:43am
Hi guys, I was wondering how the $pageComments works from the behavior tab?
I mean how you just put the variable where you want comments displayed and then enable it,
and BAM it works...I'm trying to make a JQueryImageCarousel Drop in module,
I kinda wanna get it working much like the pageComments where you can drop and go.
Any ideas, or know how about how this works?I'm going through the documentation and such now, but if someone knows that would be great.
-
Re: $pageComments Question

2 April 2011 at 6:00pm
I mean how you just put the variable where you want comments displayed and then enable it,
and BAM it works...Yes this is how it works. If you want an example of how you should do it check out the new comments module (https://github.com/silverstripe/silverstripe-comments) or more specifically the function https://github.com/silverstripe/silverstripe-comments/blob/master/code/extensions/CommentsExtension.php will help.
How this works is adds an extension to a Page object (via the comments/_config.php). That extension (which I linked above) has several functions like $CommentsForm which can be called (since that extension is now on the object).
| 424 Views | ||
|
Page:
1
|
Go to Top |


