Sometimes I love MOSS 2007, and sometimes I want to throw it right out the window. This is one of those times it should go out the window.
Im trying to come up with an easy way for a designer to update a WSS 3.0 Theme for our site. This theme is used by every site in the site collection. The following is not designer friendly (specifically step 4) as a way to update the theme...
- Designer makes edits to theme.css and copies it to production
- Change selected theme to any other theme in site settings
- Perform an IISRESET
- Re-Apply the theme in site settings
Keep in mind Themes are not inherited by subsites. Also, many times the above doesnt suffice and you also have to update the theme.inf file to increment the "version" and "format" below.
[info]
title=ThemeName
codepage=65001
version=3.10
format=3.10
readonly=true
refcount=0
Now, I have tried including into our Branding feature (which sets the masterpages and sets the theme for new sites) the ability to reset the theme. But, this doesn't really work (using an asp button to set to Wheat and another button to set it back to the custom theme). It doesn't work probably because it's not restarting IIS and updating the version numbers in the mentioned theme.inf above.
for (int x = 0; x < SPContext.Current.Site.AllWebs.Count; x++)
{
using (SPWeb site = SPContext.Current.Site.AllWebs[x])
{
site.ApplyTheme(themeName);
site.Update();
}
}
So... Have you provided a solution for your designers as a way to update/reset a Theme? If so, what was your solution? Your answer should NOT be Heathers solution, which is NOT scalable in a Farm.