方式一:
Java代码
<html>
<head>
<script src="prototype.js"></script>
<script src="jquery.js"></script>
<script>
jQuery.noConflict();
// Use jQuery via jQuery(...)
jQuery(document).ready(function(){
jQuery("div").hide();
});
// Use Prototype with $(...), etc.
$('someid').style.display = 'none';
</script>
</head>
<body></body>
</html>
<html>
<head>
<script src="prototype.js"></script>
<script src="jquery.js"></script>
<script>
jQuery.noConflict();
// Use jQuery via jQuery(...)
jQuery(document).ready(function(){
jQuery("div").hide();
});
// Use Prototype with $(...), etc.
$('someid').style.display = 'none';
</script>
</head>
<body></body>
</html>
方式二:
Java代码
<html>
<head>
<script src="prototype.js"></script>
<script src="jquery.js"></script>
<script>
var $j = jQuery.noConflict();
// Use jQuery via $j(...)
$j(document).ready(function(){
$j("div").hide();
});
// Use Prototype with $(...), etc.
$('someid').style.display = 'none';
</script>
</head>
<body></body>
</html>
<html>
<head>
<script src="prototype.js"></script>
<script src="jquery.js"></script>
<script>
var $j = jQuery.noConflict();
// Use jQuery via $j(...)
$j(document).ready(function(){
$j("div").hide();
});
// Use Prototype with $(...), etc.
$('someid').style.display = 'none';
</script>
</head>
<body></body>
</html>
方式三:
Java代码
<html>
<head>
<script src="prototype.js"></script>
<script src="jquery.js"></script>
<script>
jQuery.noConflict();
// Put all your code in your document ready area
jQuery(document).ready(function($){
// Do jQuery stuff using $
$("div").hide();
});
// Use Prototype with $(...), etc.
$('someid').style.display = 'none';
</script>
</head>
<body></body>
</html>
分享到:
相关推荐
Ajax(Ajax,jquery,prototype综合).rar
json,jQuery,prototype
最新Javascript开源框架,包含API帮助文档的学习网址。资源共享!
俩大JS框架,Jquery和Prototype
里面有现在web开发主流框架,jquery bootstrap prototype
小议JavaScript库——Dojo、jQuery和PrototypeJS的比较.pdf
包含经典电子书 CSS Jquery DHTML Prototype
javascript手册大全,其中有jquery,prototype手册的,非常全的JS手册!!!
jquery+prototype 源码 资料 插件合集 很有参考价值
CSS2.0样式表中文手册.chm CSS3.0(飘零雾雨版).chm HTML4.01&XHTML; 1.0参考手册.chm ...jquery-1.7.2.js jquery-1.7.2.min.js jQuery1.7.1_API中文手册.pdf jQueryAPI_1.7.1_CN.chm prototype1.7.js
本文实例分析了jQuery prototype冲突的2种解决方法。分享给大家供大家参考,具体如下: jquery和prototype怎么会冲突,归根到底就是因为他们二个都用到了$,同时用,混淆了。这个问题解决过不下5次,每次解决都要查...
jQuery.fn和jQuery.prototype想必大家对它并不陌生吧,那么你们知道它们之间的区别吗?在本文有个不错的示例大家可以参考下
以前好像在哪里看到过说jQuery与prototype存在冲突,但一直没在意。今天把自己用jquery框架写好的消息提示框特效放到公司原来的系统发现所有的消息提示效果都罢工了! 汗了半天还是没有发现原因,突然想到jquery与...
jQuery、Mootools、Prototype三大JavaScript框架中文手册
jQuery常用方法jQuery常用方法jQuery常用方法jQuery常用方法
jQuery是继prototype之后又一个优秀的Javascrīpt框架。其宗旨是——WRITE LESS,DO MORE,写更少的代码,做更多的事情。它是轻量级的js库(压缩后只有21k) ,这是其它的js库所不及的,它兼容CSS3,还兼容各种浏览器 ...
这是本人在学习jQuery框架Prototype的时候做的笔记,很详细
学习jQuery 必备的一些代码和方法,相信学习了本文,你可以对jQuery的学习更加容易。同时欢迎jQuery各位爱好者评论,指出不足,让我们大家共同学习,共同提升技术能力。 请关注html5cn的新浪微博@html5cn、腾讯微博@...
也支持JQuery与Prototypea共存,方法如下: 1、将jquery.js放到prototype.js后面(这个是必须的否则无论如何还是要罢工地)。 2、在jquery.js后面将$变量重命名。 方法如下: [复制此代码]CODE: ...
最新JQuery Prototype 帮助CHM格式,非常值得收藏