tabyouto / google-code-prettify

Automatically exported from code.google.com/p/google-code-prettify
Apache License 2.0
0 stars 0 forks source link

jquery $ function conflict (Firefox only) #64

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
(See attached html)
When viewed in firefox (v3) it produces this :

"functionfunction (selector, context) {
    return new (jQuery.fn.init)(selector, context);
} example function (selector, context) {
    return new (jQuery.fn.init)(selector, context);
etc...."

Or if jquery is defined before the prettyify.js, jquerys $ function is
undefined.
However everthing works fine in IE7.

Original issue reported on code.google.com by s.wjstev...@gmail.com on 8 Jan 2009 at 7:17

Attachments:

GoogleCodeExporter commented 9 years ago
Some more info, using the console in firefox, ive found that $ contains 
'</span>'
after prettyPrint is called, so re-assigning jQuery to $ brings things back to 
normal.

Original comment by s.wjstev...@gmail.com on 9 Jan 2009 at 1:23

GoogleCodeExporter commented 9 years ago
Yep.  My bad.  That's fixed in the most recent version.

Original comment by mikesamuel@gmail.com on 9 Jan 2009 at 6:02