I have copied the template 'NEW' to themes folder. And also added below code to mysite _config.php
//Theme
Config::inst()->update('SSViewer', 'theme', 'NEW');
Still the theme uses the default template 'simple'.
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
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.
I have copied the template 'NEW' to themes folder. And also added below code to mysite _config.php
//Theme
Config::inst()->update('SSViewer', 'theme', 'NEW');
Still the theme uses the default template 'simple'.
After changing the theme you need to do a ?flush=all for SilverStripe to find and cache the new templates.
The better way is probably by permanently setting the default theme to NEW in mysite/_config/config.yml (followed by ?flush=all):
SSViewer:
theme: 'NEW'
That way you can leave the theme selector in the CMS settings on default and Config::inst()->update() isn't called for it on every page request, as it is said to slow the site down...
EDIT: hmm, the new forum layout strips the two spaces before theme: 'NEW' in the code block...
it is changed to new theme now
Thanks,