21278 Posts in 5728 Topics by 2599 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 753 Views |
-
CMS picking up wrong theme...

14 March 2009 at 5:43am
Hello everyone! I'm currently in the process of setting up several test pages in Silverstripe and seem to have encountered a problem where the CMS itself is picking up a style that's intended for a particular page on my site. My _config.php is as follows (I think this is pretty well the default):
global $project;
$project = 'mysite';global $databaseConfig;
$databaseConfig = array(
"type" => "MySQLDatabase",
"server" => "xxx.xxx.xxx.xxx",
"username" => "xxxxxxxxx",
"password" => "xxxxxxxxx",
"database" => "xxxxxxxxx",
);// Sites running on the following servers will be
// run in development mode. See
// http://doc.silverstripe.com/doku.php?id=devmode
// for a description of what dev mode does.
Director::set_dev_servers(array(
'localhost',
'127.0.0.1',
));// This line set's the current theme. More themes can be
// downloaded from http://www.silverstripe.com/themes/
SSViewer::set_theme('blackcandy');When I just had a blackcandy subfolder in the themes folder then everything worked well. However, I created a page called (rather unimaginatively) test and created a subfolder called blackcandy_test in the themes folder so that I could specialise the theme specifically for the test page.
Unfortunately, when I logged out of Silverstripe and went back to its login page, the CMS itself seemed to be using the blackcandy_test theme rather than the original blackcandy. If I delete the blackcandy_test subfolder then the CMS reverts to the blackcandy theme. I've tried clearing my browser cache and the Silverstripe cache so I don't think it's caching confusion.
Have I misunderstood how theme specialisation works or have I just made a silly mistake somewhere? Any help would be greatly appreciated! Thanks!
-
Re: CMS picking up wrong theme...

15 March 2009 at 2:46pm
Did you perhaps include something in the 'editor.css' or 'typography.css' file inside your blackcandy_test/ that could be effecting the styling?.
The CMS loads the editor.css file from your theme so you can add custom class's to tinymce and style the headings, typography etc. With Blackcandy it loads typography inside editor.css (via @import) so in this case if you have something like h1 { font-size: 300%;} in typography or editor css files it will apply it to the whole CMS interface. This is why you should namespace your class's and styles in typography.css with '.typography' as that class is wrapped round the tinymce box and will not apply elsewhere in the cms
-
Re: CMS picking up wrong theme...

9 April 2009 at 1:20am
Thanks for your reply willr and sorry for not getting back to you sooner. I came to the office after your reply to find it locked up and to find myself another victim of the recession. Apparently our now business has a new owner and the doors have opened again so I should be getting back to Silverstripe in the next couple of weeks. Thanks again for your help and I'll let you know how I get on.
| 753 Views | ||
|
Page:
1
|
Go to Top |


