0
我想添加一個名爲購物車的按鈕到我的標籤腳本。如果點擊複選框,則新按鈕被控制。 (顯示)。我很困惑爲什麼圖像沒有顯示。任何答案都會有幫助。在標籤頁末尾添加圖片的問題
謝謝。 複製代碼
$(function() {
var $tabs = $('#tabs').tabs({cookie:{expires:1}});
$(".ui-tabs-panel").each(function(i){
var totalSize = $(".ui-tabs-panel").size() - 1;
var prevImage = "custom/images/prev.png";
var nextImage = "custom/images/next.png";
var atcImage = "custom/images/cart.jpg";
if (i != 0) {
prev = i;
$(this).append("<img href='#' class='prev-tab mover' rel='" + prev + "' src='" + prevImage + "'></img>");
}
if (i != totalSize) {
next = i + 2;
$(this).append("<img href='#' class='next-tab mover' rel='" + next + "' src='" + nextImage + "'></img>");
}
if (i > 1) {
atc = i + 2;
$(this).append("<img href='#' class='atc-tab mover' rel='" + next + "' src='" + atcImage + "'></img>");
}
$('input[name=FIELD_469]').click(function() {
if (this.checked) {
$("img[src*=cart]").show();
}
else {
$("img[src*=cart]").hide();
}
});
$('.next-tab, .prev-tab, .atc-tab').click(function() {
$tabs.tabs('select', $(this).attr("rel"));
return false;
});
});
嘿,問題是這是一個網站,是一個電子商務的內部網站,所以我不能顯示它.. – Cam 2012-08-09 15:08:42
好吧。讓我知道你是否仍然有問題。 – Vahan 2012-08-09 15:20:53