Stack overflow error in Internet Explorer with Nivo Slider

Internet Explorer was giving a ‘Stack over flow error at line 1010 after integrating Nivo Slider in a WordPress template.

Debugging the page using FireBug in FireFox browser I found that there was also an error saying:

too much recursion:

return (inline === false ? this.toArray() : this)._reverse();

Then using Google I found the solution;

I tracked it to Prototype.js and then to the Nivo Slider script. This error occurs everytime the Nivo Slider script is finished with it’s loop through the images and is about to begin the loop again.

I had the very same issue and I resolved modifying jquery.nivo.slider.js or jquery.nivo.slider.pack.js at the very bottom from:

 

$.fn._reverse = [].reverse;

to

$.fn._reverse = []._reverse||[].reverse;

Now the libary works with or without prototype.js, choosing the right function.

UPDATE:
for the new version 2.7.1 of jquery.nivo.slider.pack.js you need to change:

a.fn._reverse=[].reverse

to

a.fn._reverse=[]._reverse||[].reverse

 

0 Reacties

Voeg toe →

Geef een reactie