Forum: Rails Spinoffs (closed, excessive spam) 1.6.0.2 IE Error on Insert

370b423d2fb3458e442f244f40cf9cf4?d=identicon&s=25 unknown (Guest)
on 2008-01-29 15:29
(Received via mailing list)
In my current project, I'm using the prototype window class found
here: http://prototype-window.xilinus.com/download.html

I've been using it up to prototype 1.6.0.1 without any problems what
so ever. However, after the recent upgrade to 1.6.0.2, I've
encountered an error in internet explorer 6 & 7.

Before I continue, here is the test case:

http://sandbox.protopository.com/samples/multi_modal.html

Steps to replicate:

Click the link "Open a modal window".

Error Message: 'style' is null or not an object (line 2252
prototype.js)

Here are my findings thus far:

1. The problem occurs in function _checkIEOverlapping in file
window.js
2. For arguments sake, I tried switching the function to be more
compliant of new version with no luck:

 this.element.insert({after: '<iframe id="' + this.element.id +
'_iefix" '+
'style="display:none;position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);"
' + 'src="javascript:false;" frameborder="0" scrolling="no"></
iframe>'});

3. This error does not occur in firefox (tested by removing the
browser check "if" statement in the checkIEOverlapping function).
4. When this error occurs in the getStyle function, the element
nodeType is 9.

I have contacted the author of this great class, but I'm a little
pushed for a deadline...

Thanks,
Ian
140f1cb88275f7c391504de6e99edc78?d=identicon&s=25 seb (Guest)
on 2008-01-29 18:05
(Received via mailing list)
Use trunk version, it works
Sorry for not answering berfore but you contact me yesteray at 10pm
and I have some contracts to honor before :)
370b423d2fb3458e442f244f40cf9cf4?d=identicon&s=25 unknown (Guest)
on 2008-01-29 18:14
(Received via mailing list)
Thanks Seb!

Whats the repo address, can't find it on your site?
140f1cb88275f7c391504de6e99edc78?d=identicon&s=25 Sébastien Gruhier (Guest)
on 2008-01-29 19:03
(Received via mailing list)
370b423d2fb3458e442f244f40cf9cf4?d=identicon&s=25 unknown (Guest)
on 2008-01-29 19:32
(Received via mailing list)
Just checked out the trunk and updated my test case... same result.

Any ideas?
E2a5640e912255c7a972b387ea7648c9?d=identicon&s=25 zmaj (Guest)
on 2008-02-12 15:26
(Received via mailing list)
Same problem here.. ugrading to 1.6.0.2 on IE6 .
When i use the http://svn.itseb.com/public/pwc/trunk/
i only see a 1.5.1.1 of protottype.js in it...

Any other hotfixes for this one available ?
370b423d2fb3458e442f244f40cf9cf4?d=identicon&s=25 unknown (Guest)
on 2008-02-12 17:08
(Received via mailing list)
zmaj,

Temporarily, I've been using the latest snapshot before the 1.6.0.2
release as it does not have any problems.

You can find the copy I'm using here:
http://sandbox.protopository.com/javascripts/proto...

From what I understand, development of this class for 1.6.0.2 is not
going to happen... instead they will be offering prototype ui:
http://prototype-ui.com/

I'm not using the prototype ui class b/c of problems with Internet
Explorer:
http://dev.prototype-ui.com/ticket/7

As soon as the prototype ui is stable enough, I plan to port my
project to it.
E2a5640e912255c7a972b387ea7648c9?d=identicon&s=25 zmaj (Guest)
on 2008-02-12 21:31
(Received via mailing list)
itynd,
thanky you for the information   i also downgraded to 1.6.0.1 and my
problem is gone for the momen.

What made me also wonder about 1.6.0.2 is that clonePosition in IE6
within large trees or nvery large nested tables
takes up to 15!! sec longer than with 1.6.0.1.
I saw the new code for IE offsetParent calculation for absolute
elements
and think it has somehow to do with this.
At the end i avoided clonePosition within large trees by wrinting my
own positioning logic.
DAMN IE stressed me all day long today .
9b24ffb6360169d1b29117085bb05f0e?d=identicon&s=25 Gary Liu (desp0916)
on 2008-04-23 18:23
I came upon the same problem, and here is my solution.
Change the line 1047 of the file window.js from:

    if(!this.iefix && (navigator.appVersion.indexOf('MSIE')>0) &&
(navigator.userAgent.indexOf('Opera')<0) && (this.elem
     ent.getStyle('position')=='absolute')) {

to:

    if(!this.iefix && (Prototype.Browser.IE) &&
this.element.getStyle('position') == 'absolute' && this.element.id ==
'overlay_modal') {

It works for me! :-p

unknown wrote:
> In my current project, I'm using the prototype window class found
> here: http://prototype-window.xilinus.com/download.html
>
> I've been using it up to prototype 1.6.0.1 without any problems what
> so ever. However, after the recent upgrade to 1.6.0.2, I've
> encountered an error in internet explorer 6 & 7.
>
> Before I continue, here is the test case:
>
> http://sandbox.protopository.com/samples/multi_modal.html
>
> Steps to replicate:
>
> Click the link "Open a modal window".
>
> Error Message: 'style' is null or not an object (line 2252
> prototype.js)
>
> Here are my findings thus far:
>
> 1. The problem occurs in function _checkIEOverlapping in file
> window.js
> 2. For arguments sake, I tried switching the function to be more
> compliant of new version with no luck:
>
>  this.element.insert({after: '<iframe id="' + this.element.id +
> '_iefix" '+
> 
'style="display:none;position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);"
> ' + 'src="javascript:false;" frameborder="0" scrolling="no"></
> iframe>'});
>
> 3. This error does not occur in firefox (tested by removing the
> browser check "if" statement in the checkIEOverlapping function).
> 4. When this error occurs in the getStyle function, the element
> nodeType is 9.
>
> I have contacted the author of this great class, but I'm a little
> pushed for a deadline...
>
> Thanks,
> Ian
9a2979287b946a2c8a01199575d31360?d=identicon&s=25 Ryan Spohn (rws1000)
on 2008-07-09 00:06
Gary - your fix works perfectly for me. Thanks!

Gary Liu wrote:
> I came upon the same problem, and here is my solution.
> Change the line 1047 of the file window.js from:
>
>     if(!this.iefix && (navigator.appVersion.indexOf('MSIE')>0) &&
> (navigator.userAgent.indexOf('Opera')<0) && (this.elem
>      ent.getStyle('position')=='absolute')) {
>
> to:
>
>     if(!this.iefix && (Prototype.Browser.IE) &&
> this.element.getStyle('position') == 'absolute' && this.element.id ==
> 'overlay_modal') {
>
> It works for me! :-p
>
This topic is locked and can not be replied to.