Closed Bug 104856 Opened 23 years ago Closed 23 years ago

Almost blank page

Categories

(Core :: Layout, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla0.9.9

People

(Reporter: marc.loiselle, Assigned: harishd)

References

()

Details

Attachments

(2 files)

Going to the referenced url results in a most blank page.  The background is
blue and there is one ad but the rest is blank.  The scrollbar indicates that
something should be there.  Netscape 4.75 displays the page fine.

Buildid 2001101221 on Linux
Happens everytime
page is displayed just fine on 20011014 on win2k
Be patient!
The page took exacty 7mn 10s to render on
300 MHz Pentium NT4 2001101408 compared to 3s
with IE 5.5.
The second time I tried (after emptying the cache)
I gave up after 9 mn.
Confirming there is a problem with this page.
Interesting: if I remove the LINK to /includes/pulldown_pga.css then it loads
instantly... investigating.
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Even more interesting: if I add the style rules from the file pulldown_pgs.css
directly to the <head> it renders instantly. I bet the stylesheet is coming in
slowly and is causing some nasty stylesheet-appended reframes or something.
Still seeing this with 2001102910 on linux.
Keywords: perf
Target Milestone: --- → mozilla0.9.9
Seeing this on Win2k also 2001103003

Setting os to all
OS: Linux → All
Does not happen everytime on Windows.
Happens everytime with Linux.
build 2002010608 win32 trunk

Seeing the problem on and off. My guess is that the first stylesheet that has
138 rules is somehow causing problems.

                   #rules
first stylesheet   138
second stylesheet  11
third stylesheet   12


there is this line:
<script language="javascript1.1" defer
src="http://a1604.g.akamai.net/f/1604/2007/1h/stats.hitbox.com/js/hbe-v65-no10.js"></script>

does the "defer" attribute do anything in moz? I still don't know what causes
the page to appear though (setting visibility to visible).

ok this has nothing to do with performance or layout. I'm guessing this is some
kind of weird parser bug. It seems that whenever you don't see the content of
the page it is due to this block of code:

---------------------------------------------------------------------------------

<a href="http://www.pgatour.com/players/pgatour.html" class="ddNav2">PGA TOUR</a> | 
<a href="http://www.pgatour.com/players/seniortour.html" class="ddNav2">SENIOR
TOUR</a> | 
<a href="http://www.pgatour.com/players/htour.html" class="ddNav2">BUY.COM</a> | 
<a href="http://www.golfweb.com/players/lpgatour/index.html"
class="ddNav2">LPGA</a> | 
<a href="http://www.golfweb.com/players/europeantour/index.html"
class="ddNav2">European</a> | 
<a href="http://www.pgatour.com/information/2002_exempt.html"
class="ddNav2">All-Exempt Categories</a> | 
<a href="http://www.pgatour.com/players/features.html" class="ddNav2">Features</a>
&nbsp;&nbsp;
</td></tr></table>
</div>

---------------------------------------------------------------------------------

somehow becomes a comment. This causes the rest of the page become part of one
of the hidden divs.
Keywords: perf
Still seeing in Win XP Pro build 2002 0130 03.

One of my favorite parts of the pgatour.com site and I have to cut and paste
into IE every week. ;)
It looks like this is the problem (see line 49 of generated html).

<script language="javascript">
document.write("<\!--");
</script>

If I substitute the above with the following, the page is displayed.

<script language="javascript">
document.write("<!--");
</script>

So it is indeed a parsing problem with the escape character.  The ! does not
need to be escaped.  Perhaps the code is not handling that correctly.
If line 50 in the generated html is document.write("<\!-"); the page displays 
correctly and the mouseover menu works as well.  The mouseover menu did not 
work with document.write("<!--");
The \ in <\!-- is needed for older browsers I think. At any rate the document
structure in moz is something like this when I remove the stylesheets:

<body>
   <table>
   ...
   <script id="_hbc">
   <script defer src="...">
   <script><!-- //
     document.write("<\!--");
   //--></script>
   #comment
-------------------------------------------------------------------------------
     <!--clear hitbox comment
-------------------------------------------------------------------------------
   <table>
   <div id="nav0">
     <script>
       <table>
       <tbody>
       <tr>
         <td class="ddNav2">
           <script>
             <!-- //
             if(NS4) document.write('<span class="ddNavNS"> Players: </span>')
             // -->
         <a class="ddNav2"> ...  <a class="ddNav2">
   <div id="nav1">
     <script>
     <!-- //
     function onMouseOver() {isOverDiv='nav1';};
     function onMouseOut() {triggerOff('1');};
     // -->
     <table> ...
   <div id="nav2"> ... <div id="nav9">
   <table>
   <table>
   <map>
   <table>
   <table>
   <div class="table1">
   <p>

with the stylesheet, I get this:

<body>
   <table>...
   <script id="_hbc">
   <script defer src="...">
   <script><!-- //
     document.write("<\!--");
   //-->
   #comment
-------------------------------------------------------------------------------
     clear hitbox comment
-------------------------------------------------------------------------------
   <table>
   <div id="nav0">
     <script>
     <table>
     <tbody>
     <tr>
       <td class="ddNav2">
         <script>
         <!-- //
          if(NS4) document.write('<span class="ddNavNS"> Players: </span>')
         // -->
         </script>
         #comment
-------------------------------------------------------------------------------
           <a class="ddNav2"> ...
           <a class="ddNav2">
           </td></tr></table>
           </div>
           <div id="nav1">
           <script language="JavaScript">
           <!-- //
             function onMouseOver() {isOverDiv='nav1';};
             function onMouseOut(){triggerOff('1');};
           //
-------------------------------------------------------------------------------
         <table>
         <div id="nav2"> ... <div id="nav9">
   <table>
   <table>
   <map>
   <table>
   <table>
   <div class="table1">
   <p>

with the stylesheet but changed the <\!-- to <!-- , I get this:

<body>
   <table>...
   <script id="_hbc">
   <script defer src="...">
   <script><!-- //
     document.write("<!--");
   //--></script>
   #comment
-------------------------------------------------------------------------------
     <!--clear hitbox comment-->  
     <table> ...
     <div id="nav0">
     <script>
     <!-- //
       function onMouseOver() {isOverDiv='nav0';};
       function onMouseOut() {triggerOff('0');};
     // -->
-------------------------------------------------------------------------------
   <table>
     <tbody>
     <tr>
       <td class="ddNav2">
         <script>
         <!-- //
          if(NS4) document.write('<span class="ddNavNS"> Players: </span>')
         // -->
         </script>
         <a class="ddNav2"> ... <a class="ddNav2">
   <div id="nav1"> ... <div id="nav9">
   <table>
   <table>
   <map>
   <table>
   <table>
   <div class="table1">
   <p>

_basic, sounds like you are thinking this is a parser issue?  Harish, can you
check it out?
Assignee: attinasi → harishd
Status: ASSIGNED → NEW
To see the content model type javascript:alert(document.body.innerHTML); on the
URL bar. I see the TABLE in the content model but it's not rendered.
attachment 67839 [details]
build 2002013003 win32 trunk

on first load I see the red table cell, and in DOM Inspector I see this tree.
BODY
  SCRIPT          id=_hbc
    var _pn=location.pathname;
    .
    .
    .
    var _gn="ehg-sportsline.hitbox;
   SCRIPT
    document.write("If you can see a table with red background then the bug is
fixed <\!--");
   #text 
     If you can see a table with red background then the bug is fixed
  TABLE
    TBODY
      TR
        TD
  DIV               id=nav0
    SCRIPT
      <!-- //
      function onMouseOver() {isOverDiv='nav0';};
      function onMouseOut(){triggerOff('0');};
      // -->
  DIV               nav9
    SCRIPT
      <!-- //
      function onMouseOver() {isOverDiv='nav9';};
      function onMouseOut() {triggerOff('9');};
      // -->
  TABLE
    TBODY
      TR
        TD
          #text
            cell
          #comment
            /includes/gn.inc




On reload I do not see the red table cell, and in DOM Inspector I see this tree.
BODY
  SCRIPT          id=_hbc
    var _pn=location.pathname;
    .
    .
    .
    var _gn="ehg-sportsline.hitbox;
   SCRIPT
    document.write("If you can see a table with red background then the bug is
fixed <\!--");
   #text
     "If you can see a table with red background then the bug is fixed"
  TABLE
    TBODY
      TR
        TD
  DIV               id=nav0
    SCRIPT
      <!-- //
      function onMouseOver() {isOverDiv='nav0';};
      function onMouseOut(){triggerOff('0');};
      // -->
  DIV               nav9
    SCRIPT
      <!-- //
      function onMouseOver() {isOverDiv='nav9';};
      function onMouseOut() {triggerOff('9');};
      // -->
    #comment
      </div>
      <table border=1><tr>
      <td bgcolor=red>cell<!-- /includes/gn.inc 
oh yeah...I see an unclosed comment in the content model. That explains it.
The unclosed comment is the document.written comment!. Not sure how the comment
alone got inserted in the wrong place.
the weird thing is that sometimes it happens and sometimes it does not happen.
Could this have something to do with cache?
_basic: It's a parser bug. The open comment, that is document.written, is
getting handled lazily. 
After tokenizing script content we normally flush the tokenizer stack. However,
when the parser got blocked, on loading an external style sheet, we lost that 
( flush )information and hence proceeded tokenizing the rest of the document
before the script content got handled completely.
Comment on attachment 68165 [details] [diff] [review]
patch v1.0 [ bug fix + clean up ]

>Index: src/nsParser.cpp
>===================================================================

>+#define NS_PARSER_FLAG_NONE                   0x00000000

You don't need NONE flag.

>+  mFlags = NS_PARSER_FLAG_NONE;
>+  mFlags |= NS_PARSER_FLAG_OBSERVERS_ENABLED;
>+  mFlags |= NS_PARSER_FLAG_PARSER_ENABLED;

I would say the above simply as:

    mFlags = NS_PARSER_FLAG_PARSER_ENABLED; // Reset
    mFlags |= NS_PARSER_FLAG_OBSERVERS_ENABLED;


r=heikki
Attachment #68165 - Flags: review+
Comment on attachment 68165 [details] [diff] [review]
patch v1.0 [ bug fix + clean up ]

Or even better:

 mFlags = NS_PARSER_FLAG_PARSER_ENABLED | NS_PARSER_FLAG_OBSERVERS_ENABLED;

sr=jst
Attachment #68165 - Flags: superreview+
Fix is in.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
confirming w2k fixed.. 2002-14-03 build;  respin builds seem to include this fix, 

reporter is it fixed for you?
wfm with buildid 2002021506 on Linux.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: