我的jQuery:无法使用切换jQuery中
$('#imgCancel').toggle(function() {
$.each($("#List li"), function (index, item) {
$('#menuList li').removeClass("Selected");
});
$('#txtName').html('');
$('#imgAdd').show();
$('#imgUpdate').hide();
});
}, function() { //Eroor ---- Expect identifier or string
$('#List li:First').addClass("Selected");
$('#imgAdd').hide();
$('#imgUpdate').show();
});
}
});
但它不是处理toggle.I一种合适的方式得到error.How来执行切换PLZ suggest.Thanks此任务。
你得到了什么错误 – Rafay 2012-01-02 11:50:14
你得到的错误是什么。 – ankur 2012-01-02 11:50:22
你会得到什么错误?你看过jQuery文档:http://api.jquery.com/toggle/ – Pieter 2012-01-02 11:50:31