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.

Template Questions /

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

Allowing users to change templates/color schemes.


Go to End


3 Posts   2480 Views

Avatar
Xeal

Community Member, 37 Posts

18 August 2009 at 7:43am

I've been searching all over the forums for a way to do this, and the closest I've come to so far is Here. The problem with that is it only changes the theme for 1 page whereas I need it to change for the whole site. What I've done is made 5 copies of a theme and just changed the color scheme of each. I would really appreciate if someone could help me find a way to allow admins to change the theme without having to change the _config.php file.

Thanks in advance,

Xeal

Avatar
Martijn

Community Member, 271 Posts

22 August 2009 at 11:00pm

If you mean something like this:

http://www.testwebsites.net/demox

start here :

http://ssbits.com/create-a-front-end-theme-switcher/

Here it is stored in a session, but you could ofcourse store the templatevars in a dataobject.

Avatar
Xeal

Community Member, 37 Posts

25 August 2009 at 6:49am

Hey thanks a lot for this! This is exactly what I was looking for! =D

Xeal