We had javascript code (from an older version of the "Mp3 player" module) that included code like this:

/*@cc_on q=true;@if(@_win32)z=true;@elif(@_mac)w=true;@end@*/

The JSMin functionality stripped this comment out, breaking the module for IE.
JSMin+ seems to contain some special logic in regards to "@cc_on", but we haven't had a chance to test it yet.

Comments

derjochenmeyer’s picture

Status: Active » Closed (won't fix)

This bug report is related to JSMin.

Anyway, these kinds of conditional comments must be considered hacks.
var isMSIE = /*@cc_on!@*/false;

There are cleaner ways to switch js behaviour:
http://api.jquery.com/jQuery.browser/

BillyIdle’s picture

Version: 6.x-1.3 » 6.x-1.5

I think this issue is somewhat important to fix. Even if it is a hack to use conditional compilation, there exists at least one important module here on drupal.org that utilizes a third party JS lib that uses contitional compilation, namely SWF Tools. After all this is more or less the de-facto lib for adding flash content to a page.

Searching the web I stumled across a further enhanced version of the JSMin lib already in use by this project, which incorporates a fix for this issue. It can be found here:

http://plugins.svn.wordpress.org/w3-total-cache/tags/0.9.2.1/lib/Minify/...

I hope you can update the lib in the module, such that we (and other people) don't have to run on a modified version of the module.