javascript - Multiple jquery causing conflict couldn't resolve -


i using jquery 2 purposes . 1 adding calender. other toggling between tags. when put 1 working . if comment 1st script second 1 working , if comment 2nd script 1st 1 working.

new update

here's script calender.

<link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"> <script src="//code.jquery.com/jquery-1.10.2.js"></script> <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script> <script> $(function() { $("#pickdate").datepicker({ buttonimage: 'images/date.jpg', buttonimageonly: true, changemonth: true, changeyear: true, showon: 'both', }); }); </script> 

for this

  <div class="date">due date  <input id="pickdate" type="text" placeholder="select" /></div>     

here's script toggling tabs.

<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.2.js"></script> <script> $(document).ready(function(){ $(".pro").click(function(){ $(this).addclass("selected").siblings().removeclass("selected"); }); }); </script> 

for 1

<ul class="promenu"> <li class="pro" > <a href="#">one-time</a> </li> <li class="pro selected" > <a href="#">recurring</a> </li> </ul> .pro a{ display: block; padding: 3px 20px; text-decoration: none; color: black;        } .selected{ background:#47abcc; } .promenu .selected a{ color:#fff; background:#47abcc; } 

how resolve this.?

you don't need include reference jquery once per script tag, need once.

so in case, i'd remove <script type="text/javascript" src="http://code.jquery.com/jquery-1.6.2.js"></script> , keep reference version 1.10.2. can keep reference jquery ui.


Comments