style_08022010.1.css).If I were just
style.css, any changes I make to it could take up to 24 hours to propagate.
This means that I updated my
header.php to load this new style sheet instead and have no more need for a
style.css. That is, until I realized that the absence of a
style.css causes WordPress to think a theme is broken, and if you go to the theme selector page or editor e.g., it realizes this and will disable it, saying 'Stylesheet is missing'. So I needed one after all.
My question evolves around the best way to handle this situation, with the least amount of work required whenever a style sheet is renamed.
At first I thought I'd simply add a symlink from
style.css to the actual style sheet, but that would have to be updated every time I push out a new style sheet change on top of editing header.php. You can't have a blank
style.css either, since the comments in the header of it need to contain the style sheet name/description/tags etc. I could add an
@import rule to the original style sheet, but then that has to be updated every time too.
Ideally, I don't want to even change the header. I'd love to have some kind of succinct way in PHP to say 'include the first file matching '
style_*.css', but you need to use
readir for that and it's a lot of overkill.
So right now, I have a static
style.css with no
@import rule and just the standard fields in the header comment. It doesn't get loaded by anything from the site and exists only to keep WordPress happy. Whenever I push out a new style sheet change, I rename the old one and modify
I did briefly look into using the
stylesheet_uri filter to dynamically override what style sheet is loaded, but WordPress is still hard coded to look for
style.css or it thinks a theme is broken.
Looking forward to hearing anyone else's thoughts on this.