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.

Customising the CMS /

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

Adding a new tab to Content

Go to End

3 Posts   4315 Views


Community Member, 3 Posts

12 June 2009 at 5:44am

Hi guys,

I want a new tab in the Content tab right next to the metadata tab...
for example Main ||Metadata || Job Listing

I'm new to silverstripe and i tried the following code from the tutorial...but its not working

function getCMSFields() {
$fields = parent::getCMSFields();
$fields->addFieldToTab('Root.Content.Main', new Tab('JobListings'), 'Content');
return $fields;

Can anybody help me around ?


Community Member, 6 Posts

13 June 2009 at 1:27am

This should do the trick.

$fields->addFieldToTab('Root.Content.JobListings', new TextField('Foo'));

You might also have a look at the API Docs to see what the parameters do here.


Community Member, 3 Posts

17 June 2009 at 8:59am

That works . Thanks a lot :)