Итак, в основном весь сайт работает с jQuery версии 1.9.1. Хотя, я бы хотел использовать плагин, который использует только версию 1.4.1. Есть ли что-то маленькое, которое должно быть изменено в этом коде плагина, чтобы он был совместим с 1.9.1?Почему мой jQuery не работает с версией 1.9.1?
Я пробовал несколько вещей, таких как преобразование его в обычный Javascript (не повезло) и попытка загрузить версию 1.4.1 aswel .. хотя это только заставило многие другие вещи на моем сайте не работать.
$(document).ready(function() {
// Get all the thumbnail
$('div.thumbnail-item').mouseenter(function(e) {
// Calculate the position of the image tooltip
x = e.pageX - $(this).offset().left;
y = e.pageY - $(this).offset().top;
// Set the z-index of the current item,
// make sure it's greater than the rest of thumbnail items
// Set the position and display the image tooltip
$(this).css('z-index','15')
.children("div.tooltip")
.css({'top': y + 10,'left': x + 20,'display':'block'});
}).mousemove(function(e) {
// Calculate the position of the image tooltip
x = e.pageX - $(this).offset().left;
y = e.pageY - $(this).offset().top;
// This line causes the tooltip will follow the mouse pointer
$(this).children("div.tooltip").css({'top': y + 10,'left': x + 20});
}).mouseleave(function() {
// Reset the z-index and hide the image tooltip
$(this).css('z-index','1')
.children("div.tooltip")
.animate({"opacity": "hide"}, "fast");
});
});
Эти ошибки я ПОЛУЧАТЬ:
Failed to load resource: the server responded with a status of 404 (Not Found) http://jqueryui.com/slider/jquery-ui.js
Uncaught ReferenceError: jq141 is not defined (index):574
2999 (index):660
Failed to load resource: the server responded with a status of 404 (Not Found) http://www.ozcaravan-sales.com.au/wp-content/themes/listings/style/images/ui-bg_glass_75_e6e6e6_1x400.png
Failed to load resource: the server responded with a status of 404 (Not Found) http://www.ozcaravan-sales.com.au/wp-content/themes/listings/style/images/ui-bg_flat_75_ffffff_40x100.png
Failed to load resource: the server responded with a status of 404 (Not Found) http://www.ozcaravan-sales.com.au/wp-content/themes/listings/style/images/ui-bg_highlight-soft_75_cccccc_1x100.png
Failed to load resource: the server responded with a status of 404 (Not Found) http://dev.wizie.com/team/http://mangocell/favicon.ico
event.returnValue is deprecated. Please use the standard event.preventDefault() instead.
Вы получаете ошибки? – j08691
У нас есть jsfiddle.net? – underscore
@ j08691 - Мне удалось немного исправить это, объявив версию 1.9.1 непосредственно перед кодом плагинов. Хотя, это вызывает большие нарушения в других вещах на моем сайте ... Любые предложения? Это потому, что я объявляю это дважды? – Fizzix