Reputation: 937
I have a jsp page where I have a data table. I use the following scripts in the page:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js"></script>
I also ad a script for the datatables:
<script src="assets/scripts/jquery.dataTables.js"></script>
This does not work. When I set the table as a datatable nothing happens. If I replace the jquery scripts with this:
<script src="assets/scripts/jquery-1.11.1.min.js"></script>
The data table works but some other java script menu functionalities in the page stop working (Im using a template). I need to keep the menu functionality and to include a data table in the page. Is this a problem with versions conflicting? If so, then how do I solve it? Thanks.
EDIT: SHOW DATATABLE CODE:
Here is the jquery for the data table:
$(document).ready(function() {
$('#theTable').DataTable({"sPaginationType": "full_numbers", "bPaginate": true, "bSortClasses": false});
});
Upvotes: 0
Views: 93
Reputation: 612
UPDATE2 :
Use jQuery.noConflict
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js"></script>
<script type='text/javascript'>
var $jq164 = jQuery.noConflict(true);
</script>
<script src="assets/scripts/jquery-1.11.1.min.js"></script>
<script src="assets/scripts/jquery.dataTables.js"></script>
And use for other java script menu functionalities $jq164('.selector_menu') ...
Upvotes: 1