Menu

#3757 JavaScript errors when scrolling page in IE

open
None
5
2006-08-29
2006-08-29
No

In the IE advanced options ensure that "Disable
script debugging (Internet Explorer)" is NOT checked
(i.e. debugging is enabled).

Open any article (e.g. this one
http://slashdot.org/article.pl?sid=06/08/29/0127221\).

Scroll the page. A message box appears saying "A
runtime error has occurred. Do you wish to debug?
Line: 399 Error: Object required". The line number
varies.

The error occurs in this function:

function d2act ()
{
Position.prepare(); var xy = Position.cumulativeOffset
($('commentwrap')); var gd=($('d2act')); xy[1] = xy
[1] - Position.deltaY;

if (xy[1] < -14) {gd.style.top='4px';
gd.style.position='fixed'; gd.style.left='1em';}else
{gd.style.display='inline';
gd.style.position='fixed'; gd.style.top=xy[1] + 'px';
gd.style.left='1em'; };
}

This error has only started happening today. It
doesn't happen on the slashdot front page.

I could work around this by disabling script
debugging, but I need to use script debugging.

Discussion

  • Tim Vroom

    Tim Vroom - 2006-08-29
    • assigned_to: nobody --> tvroom
     
  • Ben Del Vacchio

    Ben Del Vacchio - 2006-08-30

    Logged In: YES
    user_id=1357101

    This is also happening in Safari 2.0.4 on OS X 10.4.7.

    It appears the window.onscroll event handler is being assigned the d2act
    function on the line before this function is defined. Moving this assignment
    below the function, or simply changing to 'window.onscroll = function()
    { Position..." should correct the issue.

     
  • HeroHog

    HeroHog - 2006-08-31

    Logged In: YES
    user_id=1105917

    This Does NOT occour if I go stright to /. via
    http://www.slashdot.org. It happens when I follow a link
    from the RSS feed: http://rss.slashdot.org/Slashdot/slashdot

    The MS debugger shows the offending line as:
    if (xy[1] < -14) {gd.style.top='4px';
    gd.style.position='fixed'; gd.style.left='1em';}else
    {gd.style.display='inline'; gd.style.position='fixed';
    gd.style.top=xy[1] + 'px'; gd.style.left='1em'; };

    OS: XP-Pro
    Browser: IE7 Release Candidate 1.
    Dual Monitors
    Primary Resolution: 1600x1200
    Secondary Resolution: 800x600
    Font: Medium Default

    Screenshot available at:
    http://www.herohog.com/images/misc/slashdoterror.jpg

     
  • Jehan Bing

    Jehan Bing - 2006-09-01

    Logged In: YES
    user_id=132894

    This happens in Firefox 1.5.0.6 too.

    Also, when several windows are open on slashdot pages,
    scrolling is really slow (doesn't happens with tabs). Maybe
    it's because of the Firebug extension which displays the JS
    error count in the status bar, value that gets refreshed in
    all the windows.

     
  • Erik Funkenbusch

    Logged In: YES
    user_id=804370

    This is *REALLY* annoying. It makes it almost unusable. I
    recommend this be moved to a much higher priority. Why
    don't all developers have javascript debugging turned on?
    This would be so easy to detect before rolling it out to
    production.

     
  • danielrcollins

    danielrcollins - 2006-09-05

    Logged In: YES
    user_id=1590819

    New here, also reported as bug [ 1552341 ].

    In MS Script Debugger, it specifically highlights the
    line "gd.style.display='inline'" in the block pointed out
    above.

     
  • danielrcollins

    danielrcollins - 2006-09-05

    Logged In: YES
    user_id=1590819

    I'll just add that this bug makes Slashdot news pages
    entirely unusable in IE as long as it persists.

     
  • Charles Reilly

    Charles Reilly - 2006-09-13

    Logged In: YES
    user_id=352851

    This has been fixed for me. (IE6 in XP SP2.)

     
  • Jehan Bing

    Jehan Bing - 2006-09-14

    Logged In: YES
    user_id=132894

    Yes, it's fixed for me too

     

Log in to post a comment.