zefer / Combine

Serves Combined & compressed js & css with caching, using ColdFusion
11 stars 7 forks source link

remove extra charset declarations from css-Chrome & Safari bug #1

Closed charlietfl closed 14 years ago

charlietfl commented 14 years ago

I'm in process of integrating combine and it is a great tool! All of my css files have "@charset "utf-8"; declaration. Combined files keep multiple declarations as each file is added to combined file.

So far IE 7 & 8 and FF3.6 seem to ignore the extra declarations but Chrome and Safari ( on PC) don't like the first rule after each new declaration in middle of file. I can manually remove them but I also built a flag to write full links out for each css file for debugging purposes as well.

Any feedback greatly appreciated

charlietfl commented 14 years ago

resolved by removing the charset declaration from my css files. Was a habit I was always in, however doesn't appear necessary. Combine is working great. I do a lot of UI with jQuery on a fairly large site and have a lot of different css and script files. Is great to have simple method to "combine"

zefer commented 14 years ago

Hi Charlie.

Thanks for the feedback. Since the CSS compression is performed by the YUI CSS compressor, I am surprised multiple @charset declarations are included, as the documentation suggests it only leaves one: http://developer.yahoo.com/yui/compressor/css.html#syntax-28091156e64672c2e414bd59528c6f61