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.

General Questions /

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

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

Container Pages


Go to End


4 Posts   2017 Views

Avatar
D.K.

Community Member, 20 Posts

13 February 2009 at 5:16pm

Edited: 13/02/2009 5:20pm

I'm using the nestedurls branch to power my website. Can I create a content type that seems like a page to SS but cannot be directly accessed? Currently I can create a /content/abc URL by create a content page and an abc page (with the actual content) under it. But this means that I need to put content in the content page, which I do not want. How can I create a container page that adds to the structure of the site tree, but cannot be directly accessed? (/content returns 404, but /content/abc doesn't)

Thanks in advance.

Avatar
D.K.

Community Member, 20 Posts

13 February 2009 at 6:01pm

I can restrict the /content page's access rules to just Adminstrator viewing, but it is very crude, as the links still show in the nav menus and if anonymous tries to visit /content, they get a nice login screen that says "That page is secured. Enter your credentials below and we will send you right along.", but no one will be sent along, as it is an Administrator only page. Is there a way to create a page that no one can access, does not show in nav, just performs the function of improving the site URL structure?

Avatar
ajshort

Community Member, 244 Posts

13 February 2009 at 6:12pm

Just do the restrict to admin thing, and theres also a little checkbox in the Beahviour tab that allows you to hide the page from menus and search results. I think this is what your looking for?

Avatar
D.K.

Community Member, 20 Posts

14 February 2009 at 4:09am

Edited: 14/02/2009 4:17am

Sure, that would work. But is there a way for it to return the 404 page (on the protected page, if credentials are not applied) instead of a login screen?