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

CMS page changed with theme change

Go to End

9 Posts   1758 Views


23 January 2009 at 8:33am Community Member, 26 Posts


I'm on day 2 of SS discovery. Having a blast and looking forward to really getting my teeth into it.

I am having an obscure problem that I see was reported in an archived forum post - there didn't seem to be much of a resolution. I have created a custom theme, defined a new and edited the _config file to set the theme. The problem is that when I now try to log in to the CMS I see my new (the $Content variable gives "Enter your email address and password to access the CMS." and, obviously, there are no fields etc. I have attached the screenshot - excuse the embarrassing design.

I haven't changed anything in the CMS folder - I see that there are a bunch of templates there but can't see which would render the log in page.

Any help would contribute to my marginal sanity!

PS: I notice that this $%ppy table-based layout fails in Firefox - it's fine in IE. I'd be interested if anyone can point out why that may be the case - I've emptied layout.css...

Attached Files

23 January 2009 at 8:47am Community Member, 501 Posts

Just to make sure, have you added the $Form variable as well?



23 January 2009 at 9:31am Community Member, 26 Posts

No. My intention was not to modify the way the CMS works yet at all. I assumed that it is entirely independent of any new theme I define...


23 January 2009 at 10:12am Community Member, 501 Posts

You need the $Form variable on your templates/Layout/ in order to see the form fields.


23 January 2009 at 10:21am Community Member, 26 Posts

I'm sorry - I don't understand. Are you saying I have to build the log in page from scratch if I define a new theme? I would have thought that the CMS would be unaffected by the addition of a theme...

I must be missing something here!


23 January 2009 at 10:30am (Last edited: 23 January 2009 10:30am), Community Member, 501 Posts

Noo! :)

In the template where you have $Content, you also need to add in $Form. Only that tag or variable or how you want to call it.

If you don't have $Form in it, it won't render the loginform.


23 January 2009 at 10:25pm Community Member, 26 Posts

Thanks... I think I may understand the source of my confusion. If I'm not mistaken, the login page is rendering based on the specification of the active theme. This is backed up by the fact that if I include the $Form variable in my I can log in and the CMS then renders as expected.

This still seems strange to me - surely the log in page should render according to an independent template? Is there a way of achieving this?


25 January 2009 at 3:23pm Forum Moderator, 5511 Posts

The login form is rendered in the default template, if you want a custom login template you can create a template in your themes templates/Layout folder

Go to Top