Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
How to put jQuery back into "conflict" mode
Old 06-01-2010, 09:39 AM How to put jQuery back into "conflict" mode
TWD
TWD's Avatar
King Spam Talker

Posts: 1,190
Trades: 0
...for want of a better word.


In order to avoid clashes with Prototype JS library I often preface my
jQuery scripts with this:

Code:
var $j = jQuery.noConflict();

$j(document).ready(function(){......
but I think it is probably also good practice to "undo" the no-conflict mode
in case there are other jQuery plugins in scripts that rely on the typical $ namespace.

How can I "undo" and return jQuery to its default status??
__________________
RATE-MY-WEBSITE.com "Free website reviews by real web professionals"
Please login or register to view this content. Registration is FREE
TWD is online now
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 06-01-2010, 12:19 PM Re: How to put jQuery back into "conflict" mode
Extreme Talker

Posts: 246
Trades: 0
Can't you just do the following:

var $ = jQuery;

or

var $ = jQuery.noConflict();

http://docs.jquery.com/Using_jQuery_...ther_Libraries
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
stbuchok is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to How to put jQuery back into "conflict" mode
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.09771 seconds with 12 queries