Click here to Skip to main content
15,889,651 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
I have to use 2 jquery in same page but only one plug is working at a time
This is my code
XML
<link href="../../css/jquery-ui1.css" rel="stylesheet" type="text/css" />
 <script src="../../jquery/jquery-1.9.1.js" type="text/javascript"></script>
 <script src="../../jquery/jquery-ui1.js" type="text/javascript"></script>

XML
<link href="../../css/calender.css" rel="stylesheet" type="text/css" />
       <script src="../../jquery/prototype.js" type="text/javascript"></script>
    <script src="../../jquery/CalendarDateSelect.js" type="text/javascript"></script>
    <script src="../../jquery/format_iso_date.js" type="text/javascript"></script>
Posted

Hello,

You can do this as follows.
HTML
<head>
<link href="../../css/jquery-ui1.css" rel="stylesheet" type="text/css" />
<link href="../../css/calender.css" rel="stylesheet" type="text/css" />
<script src="../../jquery/prototype.js" type="text/javascript"></script>
<script src="../../jquery/jquery-1.9.1.js" type="text/javascript"></script>
<script src="../../jquery/jquery-ui1.js" type="text/javascript"></script>
<script src="../../jquery/CalendarDateSelect.js" type="text/javascript"></script>
<script src="../../jquery/format_iso_date.js" type="text/javascript"></script>
<script language="javascript">
</script>
var $j = jQuery.noConflict();
</head>

Then, use jQuery as $j() and Prototype's $().

More infor can be found in JQuery Documentation[^]

Regards,
 
Share this answer
 
It should not be like that because we can use more than one plugin in a webpage.
Can you be more clear on your requirement?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900