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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Remove "Allow comments on this page?" from "Behavior" tab


Reply


2 Posts   602 Views

Avatar
DeklinKelly

Community Member, 197 Posts

10 August 2011 at 9:52am

I do NOT want the item: "Allow comments on this page?" to be displayed in the administrator tab under the "Behavior" tab.

How can it be removed?

Avatar
simon_w

Forum Moderator, 474 Posts

10 August 2011 at 10:35am

Edited: 10/08/2011 10:35am

public function getCMSFields() {
   $fields = parent::getCMSFields();
   $fields->removeByName('ProvideComments');
   return $fields;
}