Hi, I want to extend a class and found this example: http://doc.silverstripe.com/doku.php?id=recipes:adding_metatags. This works as expected so I use the same approach on the PageCommentInterface class. My code:
==mysite/code/CustomCommentInterface.php==
class CustomCommentInterface extends DataObjectDecorator {
function CustomCommentForm() {
return 'Foo';
}
}
==mysite/_config.php==
DataObject::add_extension('PageCommentInterface', 'CustomCommentInterface.php');
==mysite/templates/Layout/ArticlePage.ss==
$CustomCommentForm ('Foo' is not showing up!?)
Thanks for your time!
Note. I asked this before but the old forum is archived. I got a reply from howardgrigg (thanks for that!) but I don't want to alter the core.