0
我有3個箱子,一旦用戶將鼠標懸停任何,如果變化大主要股利從默認通過featVals hash table
jQuery和多元素懸停檢查
內容到相關的div在我的代碼if ($('#estate-feature, #carrier-feature, #cleaning-feature').is(':hover')) {
的一部分,我想檢查這3個div盒中是否有任何一個當前被徘徊,如果不顯示默認內容(defaultFeat變量)。
但是我收到了來自Google Chrome Javascript Console的Uncaught Syntax error, unrecognized expression: hover
錯誤。
我該如何解決?
問候
$('#estate-feature, #carrier-feature, #cleaning-feature').hover(function() {
var currentFeatCont = featVals[$(this).attr('id')];
headlineContent.html(currentFeatCont);
}, function() {
headlineContent.delay(600)
.queue(function (n) {
if ($('#estate-feature, #carrier-feature, #cleaning-feature').not(':hover')) {
$(this).html(defaultFeat);
}
n();
})
});
這個問題解決了,謝謝! – Hellnar