我正在使用Galleriffic插件,它可以在Chrome和Firefox中正常使用,但不适用于IE并返回 SCRIPT5009: 'e' is undefined
。
JQuery dode:
// Initialize history plugin.
// The callback is called at once by present location.hash.
$.historyInit(pageload, "advanced.html");
// set onlick event for buttons using the jQuery 1.3 live method
$("a[rel='history']").live('click', function () {
if (e.button != 0) return true;
var hash = this.href;
hash = hash.replace(/^.*#/, '');
// moves to a new page.
// pageload is called at once.
// hash don't contain "#", "?"
$.historyLoad(hash);
return false;
});
答案 0 :(得分:4)
看起来你错过了event参数。在函数调用中添加e
。
$("a[rel='history']").live('click', function (e) {
if (e.button != 0) return true;