Open GoogleCodeExporter opened 9 years ago
I have narrowed the issue down to this line in CssCompressor.java:
css = css.replaceAll("([!{}:;>+\\(\\[,])\\s+", "$1");
In fact, reducing the regular expression to this:
css = css.replaceAll("([{;])\\s+", "$1");
(with no other transformations) will reproduce the issue.
Original comment by adr...@gmail.com
on 13 Dec 2010 at 8:14
Thanks for your reply, sorry I haven't got back to you sooner.
While I haven't found a fix for this bug, I have found a workaround. This has
help you pin point the error.
Here is a snippet of the code that does not work:
html,body{height:100%;}body{background:#4d4d4d;color:#b8b8b8;font:.69em
Arial,Helvetica,sans-serif;}h1{color:#fff;font-size:1.82em;}h1
strong{color:#c2611e;}
Here is the same snippet tweaked so that it does work:
html,body{ height:100%;}body{ background:#4d4d4d;color:#b8b8b8;font:.69em
Arial,Helvetica,sans-serif;}h1{ color:#fff;font-size:1.82em;}h1 strong{
color:#c2611e;}
You will notice that after every { there is a space. It is this space that
allows the css to be parsed.
Thanks,
Jon
Original comment by jonrca...@gmail.com
on 1 Feb 2011 at 12:36
Any updates on this? I've also encountered this bug when using IE8.js and the
CSS compression in Drupal 6 together.
Original comment by djscorc...@gmail.com
on 4 Mar 2011 at 5:08
@jonrcarey Thanks for this workaround! It saved me lot of time debuging :)
Original comment by rafal.ga...@gmail.com
on 6 Apr 2011 at 4:23
In the minified version of IE9.js replace
i=A(i,K.media)}return i;
with
i=A(i,K.media)}return i.replace(/(\{)([a-zA-Z])/g,'{\n$2');
This will un-minify your CSS before parsing.
Tristan.
Original comment by t.breh...@yellmediaworks.com
on 24 Aug 2011 at 2:15
@t.breh...@yellmediaworks.com
I have tried this and can confirm that it works. Thanks for the help!
Jon.
Original comment by jonrca...@gmail.com
on 13 Sep 2011 at 10:17
I still have this problem. Using Drupal 6 too...
I tried applying the workaround from #5 on 2.1(beta4) and it doesn't work.
Original comment by felipefi...@gmail.com
on 26 Oct 2011 at 1:57
Workaround works on IE9.js - Not sure which version... It contains: timestamp:
Fri, 30 Apr 2010 20:59:18
Original comment by t.breh...@yellmediaworks.com
on 26 Oct 2011 at 7:43
Solution #5 helped. Thank you, Tristan.
Original comment by desig...@gmail.com
on 27 Jan 2014 at 12:52
Original issue reported on code.google.com by
jonrca...@gmail.com
on 19 Aug 2010 at 12:12