Mootools 1.2.4 and IE9 Bug

This forum is for reporting bugs in Joomla!. Please don't report problems with extensions in here.
Forum rules
Forum Rules
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Farsch
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Thu Sep 23, 2010 11:21 pm

Mootools 1.2.4 and IE9 Bug

Postby Farsch » Sun Oct 31, 2010 1:26 pm

Hi,

there is an issue and I think you have to solve it.
Its about Mootools 1.2.4 which Joomla 1.5 is using.
A lot of users have this bug, too, so I'will quote them:
I'm using mootools 1.2.4 and I tried out the Platform Preview 4 of Internet Explorer 9 and got a javascript exception, which broke my whole website:

SCRIPT5022: Exception thrown and not caught mootools-core.js

I posted a bug report to Microsoft about this and they got back to me.

They say that IE9 doesn't work with Mootools by design because Mootools uses a browser sniffing technique that isn't standards compliant. The IE9 team will not change this behaviour before the final release and it is, in their view, the responsibility of the Mootools developers to fix the library.

I’m not sure what causes it but I forgot to mention that it only occurs on IE9 - there is something about ‘uncaught exception’ somewhere in “newElement: function(tag, props)” (sorry I can’t check exact place right now).


The Mootools Developer says that they have solved the problem by upgrading Mootools to 1.1.5.
But Joomla uses the old one.
Now, what can we do now or what are you going to do?

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Mon Nov 01, 2010 2:25 pm

hi,
try my modified file located in :
/plugins/system/mtupgrade/mootools.js
You will have to use Joomla 1.5.21 and activate its new mtupgrade plugin

Modified file here :
http://www.box.net/shared/hqurhfhjpk

Follow the instructions as detailed here

It contains in one single file :
Core 1.2.5
More 1.2.4.4
+ a compatibility layer for Mootools 1.12, developed specifically for Joomla (and not by me).

I'd be really interested by your feedback.
If you need more instructions, just reply here.

Hope it helps.

Farsch
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Thu Sep 23, 2010 11:21 pm

Re: Mootools 1.2.4 and IE9 Bug

Postby Farsch » Tue Nov 02, 2010 10:02 pm

Hi Ghazal,
thank you for your response.
Well, I download your modified Mootools and override my Mootools 1.2.4(/plugins/system/mtupgrade/mootools.js). Everything works very well and in harmonie. Thank you!

My first question: Should I change some codes in behavior.php (mtupgrade-plugin)?
Because I found a code which is called:

Code: Select all

// Set the MooTools version string in the application object.
JFactory::getApplication()->set('MooToolsVersion', '1.2.4 +Compat');

Should I change this to 1.2.5?

My second question: What have you changed in your modified Mootools.js?
In the first I downloaded the 1.2.5-Mootools from the developer site and try to override the current 1.2.4 with no luck! Everything freezed while the mtupgrade was published.

Well but with your modified .js everything works. Can you tell, what you have done? Only copy and paste the codes from Core 1.2.5, More 1.2.4.4
+ a compatibility layer for Mootools 1.12?

Last but not least: What about the Mootools-Uncompressed data? I have to override it with something too, didn't I?

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Wed Nov 03, 2010 10:31 am

Hi,
1 - so it works error-free with IE9, as you requested ?
2 - be careful to check each new extension you install with Firefox and Firebug (Firebug for Firefox is the best JavaScript debugger, at this moment)
3 - Your first question :
if it works, leave it as it is, but this is nevertheless a good question
4- Your second question.
The answer is in my previous reply :
This one single js file could be divided into three (3) parts:
Core 1.2.5
More 1.2.4.4
+ a compatibility layer for Mootools 1.12, developed specifically for Joomla (and not by me).
5 - Your last question.
You have to understand the logic behind Mootools. It is a modular framework. It means that, except core functions, you can pick up some (useful to your development) functions and leave aside others. I guess that is why Joomla Devs included the Mootools Uncompressed file in Mtupgrade. To help savvy JS developers work on this. And re-compress the file, thus lightening its weight.
You can also develop your own (Mootools) classes.
If you are interested in this topic, best is to read this article which presents a rather detailed explanation on Mootools (and the differences with jQuery) :
http://jqueryvsmootools.com/

Hope it helps.

User avatar
likigoldenstar
Joomla! Apprentice
Joomla! Apprentice
Posts: 9
Joined: Tue Nov 27, 2007 6:09 am

Re: Mootools 1.2.4 and IE9 Bug

Postby likigoldenstar » Wed Apr 20, 2011 3:41 am

Hi, Ghazal!

Your mootoools 1.2.5 works well, thanks for your effort!

Best Regards

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Wed Apr 20, 2011 8:21 am

@likigoldenstar
You are welcome !

User avatar
ahmad
Joomla! Guru
Joomla! Guru
Posts: 903
Joined: Fri Apr 07, 2006 4:02 pm
Location: Egypt
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ahmad » Sun Jun 05, 2011 8:45 am

ghazal you are a legend ...
You just saved my day ...

THANKS!

Dupont77
I've been banned!
Posts: 11
Joined: Tue Aug 23, 2011 2:42 am

Re: Mootools 1.2.4 and IE9 Bug

Postby Dupont77 » Wed Aug 24, 2011 6:53 am

W0w^ your great :D I've been following your steps and it works "Mootools 1.2.4 which Joomla 1.5"
you've answer each of the problem that been posted.Does it work on Joomla 1.6? :pop

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Wed Aug 24, 2011 9:25 am

Hey,
Joomla 1.6 (now 1.7) is a whole different story because it's based on Mootools 1.3.2 (and 2 files ie mootools-core.js and mootools-more.js in media/system/js).

What people must be aware of is that the call too mootools in Joomla API has changed.
It is now :

Code: Select all

JHtml::_('behavior.framework');

For core only

Code: Select all

JHtml::_('behavior.framework', true);

For core and more

Working with Mootools 1.3 - Joomla! Documentation
http://docs.joomla.org/index.php?title= ... otools_1.3

One might check this when effects like accordion or scroll don't work as they are in more.js ;
http://mootools.net/more/

One the main drawback of more.js is that the file used in joomla package is quite heavy (±250k).
One solution is to build one's own file with more builder ( http://mootools.net/more/ ) while choosing one's own language (scroll to the end of the page) and keeping all Locale.en-US (date, form.validator, etc) and Locale.EU.Number.
And compress the file obtained.
I personally use this resource : http://javascriptcompressor.com/
and it works so far.
My mootools-more.js is now weighing around 96k.

Hope it helps.

Robbwell
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Fri Sep 29, 2006 12:40 pm

Re: Mootools 1.2.4 and IE9 Bug

Postby Robbwell » Thu Feb 09, 2012 3:22 pm

I am getting a "document.id is not a function" error with your mootools 1.2.5 file.

This seems to be a new feature that was added during 1.2.3 to as the Dollar Safe mode.

Is this not included in your version..?

Thanks for your time

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Thu Feb 09, 2012 7:02 pm

hi,
I am getting a "document.id is not a function" error with your mootools 1.2.5 file.
This seems to be a new feature that was added during 1.2.3 to as the Dollar Safe mode.

You are absolutely right.
Mootools 1.2.5 is ages old now (its moo 1.4.4 at this moment) and document.id is a 1.3 feature, so, yes, your script should work with the $ instead of document.id
($$ for document.getElements).

In case it doesn't solve your pb, show your code here.

... and update to j!2.5, 1.5 won't be supported any more soon.

Robbwell
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Fri Sep 29, 2006 12:40 pm

Re: Mootools 1.2.4 and IE9 Bug

Postby Robbwell » Thu Feb 09, 2012 7:14 pm

Actually I just figured out what the problem is.

TinyMCE (default Joomla! version) conflicts with your 1.2.5 version as they override document.id.

Reference: https://mootools.lighthouseapp.com/projects/2706/tickets/702-documentid-conflict-with-tinymce
Reference: http://mootools.net/blog/2009/06/22/the-dollar-safe-mode/

I have a lot of custom components to convert before I switch over all of our sites to 2.5

Thanks for your time.

Robb

ghazal
Joomla! Explorer
Joomla! Explorer
Posts: 271
Joined: Fri Aug 19, 2005 12:12 pm
Location: Out of my mind ...sometimes

Re: Mootools 1.2.4 and IE9 Bug

Postby ghazal » Thu Feb 09, 2012 11:59 pm

I have a lot of custom components to convert before I switch over all of our sites to 2.5

Good luck !
Plugins and modules are not that difficult to update.
Components are a whole different story.

Good to know about TinyMCE pb and tks for reporting this here.
Personally, I gave up on this editor long ago so I'd never have thought about troubleshooting it.

I must admit that I am quite surprised that ppl keep downloading my version of Mootools for 1.5 (1 or 2 a day since I made it available). I intended more or less to mention this to Joomla devs, but since this version is close to its end ...

ASconbs
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Wed Dec 21, 2011 11:00 am
Location: Syddanmark, Denmark
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ASconbs » Tue Mar 13, 2012 9:34 am

ghazal wrote:hi,
try my modified file located in :
/plugins/system/mtupgrade/mootools.js
You will have to use Joomla 1.5.21 and activate its new mtupgrade plugin


4 months ago I took over a Joomla version 1.5.18 site. It has worked fine until now and I did not change anything related to mootools, but suddenly it started to crash the IE9, which is freezing attempting to load the site.

It works fine in Firefox and Safari.

Could this relate to this topic, and if so, would your workaround quoted above work on the Joomla version 1.5.18 ?

User avatar
ahmad
Joomla! Guru
Joomla! Guru
Posts: 903
Joined: Fri Apr 07, 2006 4:02 pm
Location: Egypt
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ahmad » Tue Mar 13, 2012 9:45 am

Try Ghazal's fix, it will work

ASconbs
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Wed Dec 21, 2011 11:00 am
Location: Syddanmark, Denmark
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ASconbs » Tue Mar 13, 2012 11:47 am

ahmad wrote:Try Ghazal's fix, it will work

Hi Ahmad
Thank's for replying

I have the mootool.js file placed here: /httpdocs/media/system/js

Should I just replace it with the unpacked zip file from Ghazal ?

User avatar
ahmad
Joomla! Guru
Joomla! Guru
Posts: 903
Joined: Fri Apr 07, 2006 4:02 pm
Location: Egypt
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ahmad » Tue Mar 13, 2012 11:57 am

Yes but create a backup of the original file first

ASconbs
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Wed Dec 21, 2011 11:00 am
Location: Syddanmark, Denmark
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ASconbs » Tue Mar 13, 2012 1:32 pm

I did, but it does not work for me. I keep getting the warning: www.xxx.dk does not answer due to a long lasting script. The hosting company can inform me, that the problem seems to origin from the file caption.js which I think is related to the JT slideshow on the site.

ASconbs
Joomla! Apprentice
Joomla! Apprentice
Posts: 11
Joined: Wed Dec 21, 2011 11:00 am
Location: Syddanmark, Denmark
Contact:

Re: Mootools 1.2.4 and IE9 Bug

Postby ASconbs » Fri May 04, 2012 8:08 am

Hi all
I just wanted to wrap up on my last post in this thread. It turned out that my problems actually was caused by server problems at the host. I really would like hosting companies rather told us, that they have problems, than letting us in the dark. Thank Ahmad for your posts.


Return to “Joomla! 1.5 Bug Reporting”

Who is online

Users browsing this forum: No registered users and 5 guests