That said, there is one caveat: By default, jQuery uses "$" as a shortcut for "jQuery".
However, you can override that default by calling jQuery.noConflict() at any point after jQuery and the other library have both loaded.
When you use jQuery with other libraries, jQuery still is functional.
You can use jQuery directly
// Use jQuery via jQuery(...)
jQuery(document).ready(function(){
jQuery("div").hide();
});
or reassign jQuery to another shortcut
var $j = jQuery;
// Use jQuery via $j(...)
$j(document).ready(function(){
$j("div").hide();
});
For more detail, please see http://docs.jquery.com/Using_jQuery_with_Other_Libraries.
No comments:
Post a Comment