views:

74

answers:

1

Hi,

I am using the Mootools Fx.Scroll effect to navigate horizontally through my website sections. Everything is working properly with Firefox, but Internet Explorer gives me some trouble. First the section were a big mess, but after adding one line in the Mootools core file thanks to a lighthouseapp.com patch, the sections are now well displayed.

My problem is that I can not go backward (to the left), only going to the right (again, it is only with IE...). The working demo is here.

After days of unsuccessful research, I am asking for your help, for any advice. I will provide any needed details.

Thanks a lot ;)

+1  A: 

erm - couple of things.

you have commented out mootools 1.2.3.1 and gone back to 1.2.1, any reason for this?

you run to patch the framework using some code from the ticketing system, seems rather dubious to me and it most certainly should not be how you approach solving this. I am far from saying that mootools is free of errors but my point is that for such a simple transition, there can be a million other solutions than to look at the framework's ticketing system. all things being equal, it is safe to assume the problem will lie elsewhere... (and yes, I know of an error to do with Fx.Scroll that is still not patched but I don't think it would affect your setup).

for starters, my debugger on IE7 reports a JS exception on line 57 of your code:

if($('prog')) { // error somewhere here.
    progBrowser = new ProgBrowser('prog',{
     topX: '50px',
     topY: '100px',
     mouseOnColor: '#ffe400',
     mouseOutColor: '#ffffff'
    });
}

subsequently, a lot of code breaks and you get an utter mess on your screen. but there is nothing wrong with your instantiation - the problem is elsewhere: you have actually removed methods of the ProgBrowser class and left a trailing comma, check the bottom of the prog-browser.js file

    }, // this comma will always break IE.


});

as for the scrolling problem, you can try using element.scrollTo(x,y) - but in any case, you have totally rewritten the normal event handlers for the class (replacing the click event with a onclick assignment etc) - fix the exceptions and post back your error-free page and we can look at doing scrollback again. good luck :)

Dimitar Christoff
Thank you for your advice, I tried everything you told me about but I gave up and change everything to JQuery. Now everything works fine with IE, and I think I will continue to use JQuery in the future ^^The result can be tried here: http://prod.mathieulaude.com/sitePBN2009/PBN2009-4/Thanks again, see you ;)
Dimitar, what a great answer. You covered everything, well done mate. Shame they Mathieu did not stick with it and did the easy route of JQuery. Sure its good, but its just not Mootools ;)
Pete Duncanson