开发者

Nivo Slider doesn't work on webkit browsers with Really Simple History (RSH)

I am building an AJAX powered website which uses the Really Simple History (RSH) framework to handle back and forward requests.

开发者_Go百科

I'm also using Nivo Slider for a simple slideshow. In Firefox and even IE, this works fine. However, in Chrome and Safari, the first picture loads but that's as far as it gets - the navigation bullet points don't appear and the slides don't change.

The really strange thing is that there are no error messages. Not in Firebug or in Chrome's Javascript console.

I've discovered that the culprit is json2007.js which is included as part of RSH. If I comment this out (along with the rest of RSH), the slideshow works perfectly.

I originally thought that JSON and JQuery might be having problems with each other so I included JQuery-JSON but that didn't help.

Has anyone else had this problem? Is there something stupid that I've done which is causing the problem?

This is the website in question: http://camiraenergy.co.uk/. The slideshow is only available on the homepage. It should be pretty obvious. (This site is still under construction so some things don't make sense.)

Thanks for your help!

Nick


Solved it by using json2.js instead.

You have to change window.dhtmlHistory.create() to

window.dhtmlHistory.create({
  toJSON: function(o) {
    return JSON.stringify(o);
  }, fromJSON: function(s) {
    return JSON.parse(s);
  }
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜