I have a really strange problem with IE6 and would be extremely grateful for a) opinions, b) a second look and c) any help that can be offered as this thing really has me stumped.

I'm running 4.7 CVS (as of today) and all modules installed are also CVS as of today. Amongst the contributed modules that I'm running are blockbar and controlpanel. I don't think either of these two are the problem but I'm mentioning them because the problem seems to occur round about where those modules kick in.

In FF, Opera, Mozilla and IE7 (beta 2), my site displays fine, every time, every page. But in IE6 (with SP2), it doesn't. Well, not always. And it is the not always bit that has me stumped.

Sometimes pages appear fine. For example, /user nearly always appears fine. Most node pages (as far as I can tell) appear fine. But the home page appears fine only sometimes. As the attached screen_shot shows, /front_page occasionally shows up only partially rendered. The code just stops. Right about the time it starts to display the body of the page. Other times it's fine. And at this precise moment, going to root (www.vcommunity.org.uk) just gives me "Page cannot be displayed". If I attempt to go to /user, I get a similar "weird" page. But /user/register appears fine in IE6 with no problems whatsoever. If I follow a link on there to, say, the events calendar, again, displays fine.

Just what is going on!?!

I have been through every PHP file (.inc, .module) and have made sure that there are no extraneous whitespaces at the end of any file. I've reloaded every file just in case but I still get the same results.

My questions:

a) Does anyone else get this when they visit my site in IE6? Or is it just me?
b) If it is not just me, what is causing it?

I'm very grateful for any help or opinions offered.

Regards

Patrick

CommentFileSizeAuthor
#1 drupal_screenshot_sample_10.png214.41 KBPatrick Nelson

Comments

Patrick Nelson’s picture

StatusFileSize
new214.41 KB

Sorry forgot to attach screenshot.

markus_petrux’s picture

I have also observed something similar, even with current HEAD. Only partial page seems to be sent to the browser, and it only happened in IE6.

Disabling page cache solved the problem. Strange.

Patrick Nelson’s picture

Title: Weird display problem in Internet Explorer 6 » So, does this mean that the page caching system is buggy?

That worked just fine. It is as if IE6 never knew there was a problem. So, does this mean that the page caching system is buggy?

ebruts’s picture

Version: 4.7.0-beta4 » x.y.z
Category: support » bug
Priority: Normal » Critical

I can verify this with IE 6.0 SP2 and drupal cache enabled.

Marked it as critical as it will break many sites.

ebruts’s picture

Actually I did not test it on a clean install but had statistics logging enabled. Here is some debug.
This is what Internet Explorer sends

GET /?q=node HTTP/1.1
Accept: */*
Accept-Language: de
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.0.3705; .NET CLR 1.1.4322)
Host: www.example.com
Connection: Keep-Alive
-
HTTP/1.1 200 OK
Date: Sat, 25 Feb 2006 09:44:53 GMT
Server: Apache/2.0.55 (Unix) mod_ssl/2.0.55 OpenSSL/0.9.7b
Set-Cookie: PHPSESSID=9312462aa20e4c0c526faaaad7d6c971; expires=Mon, 20 Mar 2006 13:18:13 GMT; path=/
Last-Modified: Sat, 25 Feb 2006 09:44:45 GMT
ETag: "83eb41b72a25a09c584330bbb20d1c42"
Content-Encoding: gzip
Content-Length: 1559
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/html; charset=utf-8
-
HERE IS GZ-ENCODED CONTENT
Fatal error:  Call to undefined function decode_entities() in /home/eberts/drupal/cvs/modules/statistics.module on line 81

Notice the Fatal error at the end? This might prevent IE6 to correctly decode the gzip encoded content.
So the next time you try to reload the page, IE sends and receives the following

GET /?q=node HTTP/1.1
Accept: */*
Accept-Language: de
Accept-Encoding: gzip, deflate
If-Modified-Since: Sat, 25 Feb 2006 09:44:45 GMT
If-None-Match: "83eb41b72a25a09c584330bbb20d1c42"
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.0.3705; .NET CLR 1.1.4322)
Host: www.example.com
Connection: Keep-Alive
Cookie: PHPSESSID=9312462aa20e4c0c526faaaad7d6c971
-
HTTP/1.1 304 Not Modified
Date: Sat, 25 Feb 2006 09:45:50 GMT
Server: Apache/2.0.55 (Unix) mod_ssl/2.0.55 OpenSSL/0.9.7b
Connection: Keep-Alive
Keep-Alive: timeout=15, max=100

and thus uses his internal cached site (which it probably is not able to decode).

Whereas other browsers like Firefox or Opera are able to decode it correctly even with the Fatal error in plain text.

ebruts’s picture

There seems to be two problems to worry about. The first, rather simple, is about fixing statistics.module.

The other might not because it is a general problem.

/**
 * Perform end-of-request tasks.
 *
 * This function sets the page cache if appropriate, and allows modules to
 * react to the closing of the page by calling hook_exit().
 */
function drupal_page_footer() {
  if (variable_get('cache', 0)) {
    page_set_cache();
  }

  module_invoke_all('exit');
}

*_exit is called even on cached pages, that is good to have for running statistics etc. but as soon as some exit hooks start to actually output content it will cause problems with the caching system as it might (on most systems it will) transfer the cache in gzip encoding -- but the output of the exit hook will be plain text.

moshe weitzman’s picture

Component: base system » statistics.module
Priority: Critical » Normal

exit hook should not be outputting anything. if it does, it should know that stuff might not always work.

sounds like a statistics bug

moshe weitzman’s picture

Title: So, does this mean that the page caching system is buggy? » decode_entities() not found in statistics.module
ebruts’s picture

Status: Active » Fixed

Has been fixed by Dries.

http://drupal.org/cvs?commit=26849

Anonymous’s picture

Status: Fixed » Closed (fixed)