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

Editing/Adding Content to the Login page


Reply


4 Posts   1414 Views

Avatar
dizzystuff

Community Member, 93 Posts

21 February 2010 at 9:33pm

Hi All

I've tried all sorts of searches here in the forum but haven't been able to come up with much.

I'm sure I'm just in the middle of some epic brainfreeze and this is a really obvious thing -> but how on earth can an editor update the text on the /Security/login page?

Is this accessible from the CMS? If not, is there a way to create a new login page that is, and then redirect /Security/login to it?

Open to any and all weird and wonderful suggestions. Forehead-slaps will also be accepted if appropriate :)

Cheers
Luke

Avatar
Juanitou

Community Member, 323 Posts

23 February 2010 at 3:44am

Hi Luke.

Just create a Security_login.ss file in your templates folder.

Hope it helps,
Juan

Avatar
dizzystuff

Community Member, 93 Posts

13 March 2010 at 4:45pm

Hey Juan

Thanks for that, it works a treat for me as a dev being able to take control of the page. I'm still not sure how editor users could access it? It's less of an issue for me now though, thanks to you pointing out Security_login.ss. Also I've found some of the $lang stuff so I'm overwriting some of the default text for the page via my main _config.php.

***

Issue now is I'm trying to add a widget to the sidebar of /Security/login page.. but without it being in the site tree in the CMS I'm a little lost on how to do this. I might create a diff thread for this question but thought I'd ask on this one first.

Avatar
dizzystuff

Community Member, 93 Posts

13 March 2010 at 5:06pm

Actually, I've sorted the issue regarding Widgets on the Login page, in short I've added "securityLoginWidget()" function to Page_Controller which retrieves a particular widget via DataObject::get_by_id(), and then in Security_login.ss I use <% control securityLoginWidget %> to render it on screen.

Probably a little hacky, but it's doing the trick for the time being.