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've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Customising the CMS /

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

Subclassing Left and Main with several pages


Go to End


1829 Views

Avatar
Room9

Community Member, 19 Posts

8 April 2011 at 1:11pm

Hi,

I'm new to subclassing LeftAndMain and have some questions. My 'left' is a search form and 'right' is a series of pages (reports) pulling data from the database and webservices.

How would I create a series of pages under this menu? At the moment I'm trying to use defaultAction($action) to parse the url action (e.g. admin/myadmin/report1) and generate a report to go into the MyAdmin_right.ss template, but I get "The action 'report1' does not exist in class MyAdmin" (so defaultAction is not working?).

Is there an easier way to have a number of pages show under a LeftAndMain menu?