Last Comment Bug 42525 - [DOCTYPE] Transitional DOCTYPE with URI should trigger strict layout mode
: [DOCTYPE] Transitional DOCTYPE with URI should trigger strict layout mode
Status: VERIFIED FIXED
[nsbeta2-][nsbeta3-][rtm++]
: regression
Product: Core
Classification: Components
Component: Layout (show other bugs)
: Trunk
: All All
: P2 normal (vote)
: ---
Assigned To: rickg
: Chris Petersen
Mentors:
: 43274 78076 (view as bug list)
Depends on:
Blocks: 34662
  Show dependency treegraph
 
Reported: 2000-06-14 13:17 PDT by Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26)
Modified: 2002-05-27 14:49 PDT (History)
21 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Test for quirks vs. starndard mode (219 bytes, text/html)
2000-06-14 13:23 PDT, Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26)
no flags Details
Test case to verify the bug. (422 bytes, text/html)
2000-07-10 14:33 PDT, harishd
no flags Details
Test case to verify the bug [ Please ignore my previous test case ] (418 bytes, text/html)
2000-07-10 14:34 PDT, harishd
no flags Details
testcase that should display in strict mode (566 bytes, text/html)
2000-08-24 19:14 PDT, Pierre Saslawsky
no flags Details

Description Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-14 13:17:14 PDT
BuildID:    2000060908

A document with this DOCTYPE declaration:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
gets rendered in the quirks mode.

Reproducible: Always
Steps to Reproduce:
1. Load the attached testcase.

Actual Results:  The text reads: "Layout not in standard mode." That is the page is 
rendered in the quirks mode.

Expected Results:  Expected the text to show up as: "Layout in standard mode." That is 
expected the page to be rendered in the standard mode.

IE 5 for Mac allows HTML 4 Transitional documents be handled in either the standard 
mode or in the quirks mode.

A DOCTYPE declaration without a URI leads to the quirks mode.
(ie. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">)
A DOCTYPE with the URI leads to the standard mode.
(ie. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">)

Mozilla, however, handles both cases in the quirks mode. Some authors are likely to 
expect behavior similar to that of IE 5 for Mac.

Some authors really want to use the Transitional DTD but still have to page handled in 
the standard mode. Currently you can't author valid HTML 4 Transitional and have 
Mozilla display it according to the specs.

Displaying the case without the URI in quirks mode, on the other hand, provides for 
bugwards compatibility with old pages.
Comment 1 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-14 13:23:14 PDT
Created attachment 10135 [details]
Test for quirks vs. starndard mode
Comment 2 rickg 2000-06-14 15:23:37 PDT
The comment parsing code in strict mode is operating incorrectly in this case. 
The comment example: <!-->not<!-->. In this case, the word "not" is part of the 
strict comment, and should not be rendered. 
Comment 3 rickg 2000-06-14 15:25:38 PDT
Oh -- wait -- now I recall why. We decided (perhaps wrongly) to allow backward 
compatible comment handling to operate in transitional mode documents (it's the 
only area where we take liberties with the spec). 

Let me think on this one a while.
Comment 4 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-15 02:49:25 PDT
I used the comment just as a known quirk to detect the compat mode. The problem itself 
is that the transitional doctype with or without the URI leads to the NavQuirks mode while 
in IE 5 for Mac the declaration with the URI leads to the standard mode.
Comment 5 Hixie (not reading bugmail) 2000-06-15 04:31:58 PDT
There are three parser modes (DTDs) and two layout modes: 
 
   Strict DTD
   Transitional DTD
   Compat DTD

   Standard Layout  
   NavQuirks Layout

A Transitional DOCTYPE should trigger Transitional DTD. This is currently 
happening, as Rick explained. The comment thing is not a layout quirk and so
cannot be used to check Layout mode.

See also http://www.bath.ac.uk/%7Epy8ieh/cgi/compat-test.pl

(Is that all correct Rick?)
Comment 6 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-15 12:21:39 PDT
OK. I tested the wrong way.

According to http://www.bath.ac.uk/%7Epy8ieh/cgi/compat-test.pl, HTML 4 Transitional 
gets parsed in the Transitional mode and rendered in the standard mode.

Should I resolve this as invalid or leave open for comment handling consideration? 
Comment 7 Hixie (not reading bugmail) 2000-06-15 12:39:01 PDT
Rick? It's up to you if this gets marked INVALID now...
Comment 8 rickg 2000-06-15 19:22:48 PDT
As stated, the bug is invalid. But now we have a new problem:

The composer team assigned a bug to me complaining the their documents (from 
nav4X) we're not rendering correctly. As it turns out, they place a <doctype 
HTML 4.0 transitional> tag into the markup -- but then violate the transitional 
spec. Sigh.

After talking with product marketing, the only way out of this is to create a 
(non-visible) preference to control transitional doctype handling. By default, 
we will need to load transitional documents in quirk mode. The pref will allow a 
savvy user to cause transitional documents to be handled by the transitional 
DTD. It stinks, but there's no other way.

Comment 9 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-16 01:54:36 PDT
There are other ways.

IE 5 for Mac uses the URI as the preference indicator. The solution isn't ideal, but it's 
better than considering all transitional documents quirky.

Please leave the Transitional doctype with the URI as non-quirky. Otherwise this bug 
becomes valid. :-)

If Composer from 4.x is the only problematic editor that uses the 4.0 Transitional doctype 
without complying with the spec, the pages can be detected from meta tags eg. <meta 
name="GENERATOR" content="Mozilla/4.6 (Macintosh; I; PPC) [Netscape]">.

Is the string "-//W3C//DTD HTML 4.0 Transitional//EN" supposed to be case-sensitive? 
The old Composer uses "-//w3c//dtd html 4.0 transitional//en".
Comment 10 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-06-24 16:34:43 PDT
According to http://www.bath.ac.uk/%7Epy8ieh/cgi/compat-test.pl, this bug is valid as of 
build 2000062408.
Comment 11 rickg 2000-06-26 15:17:25 PDT
We have a fix in hand, which also corrects the composer issue (where composer 
claims 4.0 transitional but is not).

PDT: Please allow this fix so we can put the composer/transitional DTD issue 
behind us.
Comment 12 Jay Patel [:jay] 2000-07-06 13:58:17 PDT
Adding [NEED INFO]. Nisheeth, are we ok on this bug now?  If so, please take it 
off the radar.
Comment 13 Jay Patel [:jay] 2000-07-07 14:34:20 PDT
Putting on [nsbeta2+] radar for beta2 fix. 
Comment 14 harishd 2000-07-10 14:23:59 PDT
Reassigning to myself.  BTW, isn't this bug fixed?
Comment 15 harishd 2000-07-10 14:32:43 PDT
Okay, this is definitely fixed. Will attach a test case to verify this.
Comment 16 harishd 2000-07-10 14:33:21 PDT
Created attachment 11200 [details]
Test case to verify the bug.
Comment 17 harishd 2000-07-10 14:34:29 PDT
Created attachment 11201 [details]
Test case to verify the bug [ Please ignore my previous test case ]
Comment 18 harishd 2000-07-10 14:34:51 PDT
Marking FIXED.
Comment 19 Chris Petersen 2000-07-11 10:28:06 PDT
Marking verified fixed in the July 10th build.
Comment 20 mpetrick 2000-08-11 15:29:22 PDT
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; m18) Gecko/20000810

<A HREF="showattachment.cgi?attach_id=11201">This attachment (id=11201)</A> is 
showing up as quirks.

It is showing up as quirks here too:
http://www.bath.ac.uk/%7Epy8ieh/cgi/compat-test.pl?DOCTYPE=%3C%
21DOCTYPE+HTML+PUBLIC+%22-%2F%2FW3C%2F%2FDTD+HTML+4.01+Transitional%2F%2FEN%22+%
22http%3A%2F%2Fwww.w3.org%2FTR%2Fhtml4%2Floose.dtd%22%3E&MODE=full

can someone verify and reopen bug if necessary - thanks.
Comment 21 harishd 2000-08-11 15:51:49 PDT
Transitional DTD has been disabled ( refer bug 42388 ).
Comment 22 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-08-11 15:56:23 PDT
However, it should still trigger strict mode in layout when used with a URI. 
Reopening.
Comment 23 harishd 2000-08-11 16:19:24 PDT
This bug should then go the layout folks. This is not a parser problem anymore.
Giving bug to Mark.
Comment 24 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-08-11 16:32:03 PDT
For HTML 4.01 Transitional bug 46958 is a duplicate of this bug.
What's the plan with HTML 4.0 Transitional?
Comment 25 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-08-11 16:35:46 PDT
Right now, the parser determines the layout mode.  I could probably modify the
DOCTYPE parsing code I attached to bug 44340 to do this without too much difficulty.
Comment 26 Marc Attinasi 2000-08-11 17:05:21 PDT
Harish: layout relies upon the parser having set the mode, so if the mode is 
incorrect it is not layout (and is likely the parser).

David Baron: You seem to be on this bug (via bug 44340) so should I assign it to 
you?

Everyone: Please let me know what if anything this has to do with Layout...
Comment 27 Hixie (not reading bugmail) 2000-08-11 17:15:10 PDT
The fix for this may be usurped by the bigger change required to fix bug 48351.
Comment 28 harishd 2000-08-14 09:27:02 PDT
You're right Mark. I forgot the fact that the parser actually sets mode on 
the layout ( while back layout did this on its own ). Sorry about that. 
Assigning to myself.
Comment 29 leger 2000-08-14 14:36:13 PDT
PR2 is outta here...moving from [nsbeta2+] to [nsbeta2-].  Adding nsbeta3 
keyword.
Comment 30 Marc Attinasi 2000-08-14 15:28:10 PDT
Harish, you assignment to self didn't make it - here ya go :)
Comment 31 harishd 2000-08-21 14:06:04 PDT
Marking nsbeta3+.  Will fix this once we decided what we are doing with the 
strict dtd.  Should be an easy fix either way.  This is nisheeth typing for 
harish.
Comment 32 harishd 2000-08-21 16:37:28 PDT
*** Bug 43274 has been marked as a duplicate of this bug. ***
Comment 33 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-08-24 04:52:04 PDT
Since bug 43274 was marked a duplicate of this one, this bug is now also considered to 
cover triggering the standards layout for unknown doctypes. (Unknown XHTML doctypes 
should go down the XML + std layout code path.)
Comment 34 Pierre Saslawsky 2000-08-24 19:13:52 PDT
I'm going to attach the testcase from bug 43274. Please make sure it works 
correctly.
Comment 35 Pierre Saslawsky 2000-08-24 19:14:40 PDT
Created attachment 13459 [details]
testcase that should display in strict mode
Comment 36 harishd 2000-08-29 17:04:37 PDT
This problem would get resovled when bug 50070 gets fixed ( basically by turning
off STRICT DTD ).

Marking it a dup.

*** This bug has been marked as a duplicate of 50070 ***
Comment 37 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-08-29 17:58:56 PDT
This is a separate issue from turning off the strict DTD, since this affects
layout quirks mode.  Reopening.  If you want to fix both at once, that's fine,
but they're separate issues in the code.
Comment 38 harishd 2000-08-29 19:25:21 PDT
Rickg and several other folks seem to disagree in triggering strict layout ( 
i.e., a transitional doctype,with or without a uri,should trigger quirks layout 
). I'm therefore giving this bug to rickg for futher analysis on this issue. 
And, also, since he's been working on bug 50070. 

Over to you rickg :-)
Comment 39 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-08-29 19:33:21 PDT
We did it before, but undid it only because pages were breaking, largely due to
the Strict DTD, I think.
Comment 40 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-08-30 00:51:27 PDT
Some authors really want a way to use HTML 4 Transitional with standard layout. You 
get the benefits of standard CSS handling but can also include deprecated HTML to 
ease graceful degrading in old browsers.

It hasn't been demonstrated that too many pages break too much with CNavDTD + std 
layout for Transitional doctypes with the URI. IIRC, this combination hasn't been tested for 
Transitional doctypes with the URI. When std layout was previously enabled for these 
doctypes, the parser mode was strictly transitional and didn't deal well with bad HTML.

Not fixing this bug would leave IE 5 for Mac more standards-compliant than Mozilla in this 
scenario. None of us wants Mozilla to be less compliant than IE, right?
Comment 41 rickg 2000-09-14 16:28:48 PDT
Landed fix for "most" cases. The problem is that nav/ie don't agree on some of 
the odder cases, so we're punting on them.
Comment 42 rickg 2000-09-14 16:30:21 PDT
Oops, I closed the wrong bug. Sorry.
Comment 43 selmer (gone) 2000-09-19 22:38:13 PDT
This is very feature-ish and very unlike the P2 criteria.  pdtp5.
Comment 44 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-09-20 05:16:28 PDT
Why future a "fix in hand" nsbeta3+ bug?

This bug is not feature-ish. As indicated above, the fix for this bug is
required for the ability to use HTML 4 Transitional in a standards-compliant
way. Some authors want to use standards-compliant Transitional to get the
benefits of the standard layout mode and to allow graceful degradion in legacy
browsers.
Comment 45 Andreas Franke (gone) 2000-09-22 03:53:11 PDT
cc ekrock@netscape.com as the reporter of bug 50070 which seems to be relevant
for this one. This bug is mainly a decision what layout mode should be used
given a certain doctype. It does not make much sense to make this decision after
NS6 is out. Please review. Thanks.
Comment 46 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-09-22 07:28:52 PDT
Not fixing this bug would leave Web authors with these options:
1) Migrating to HTML 4 Strict
2) Writing doctypeless code to old bugs
3) Declaring documents Strict even though deprecated elements are used
4) Migrating to XHTML Transitional sent as text/html

* Option 1 is unavailable to authors who think (or whose clients or managers insist) that 
pages should be reasonably compatible with legacy browsers.

* With option 2 the benefits of standards layout are lost

* Option 3 would mean breaking the standards to get the standard layout in one layout 
engine. This option is not good. However, it is known that this approach has been used in 
practice to work around this bug in Mozilla. Compelling authors to break standards isn't 
at all good.

* Implementing option 4 without creating a forward-compatibility problem requires great 
care. Compelling authors to hastily declare potentially non-compliant code as XHTML 
isn't a good solution.

If the triage team thinks treating HTML 4.0 Transitional as non-quirky is too risky (even 
though IE 5 for Mac does it), please OK at least treating HTML 4.01 Transitional as 
non-quirky.
Comment 47 Hixie (not reading bugmail) 2000-09-22 18:04:13 PDT
1) is the ideal solution.
2) is what happens now, and is what you need if you want pages to be compatible
   with legacy browsers.
3) is unlikely to happen, as why would people want standards to be followed 
   if they didn't use them.
4) would be handled as normal HTML (quirks mode), as requested by the HTML WG.
Comment 48 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-09-22 18:56:39 PDT
I think we can use any indicator of XHTML (an XML declaration or an XHTML
doctype) to trigger *layout* standard mode -- just not the Strict DTD or the XML
parser.
Comment 49 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-09-23 03:06:43 PDT
I am not that convinced that authors will stay away from option 3 if this bug isn't fixed. 
Past behavior suggests that many authors will choose a hack over standards-compliance 
if the page looks better that way. AFAIK, option 3 has been used even on richinstyle.com!
Comment 50 Phil Peterson 2000-09-27 22:53:56 PDT
Not holding PR3 for this; marking nsbeta3-. Please nominate for rtm if we really
need to fix this before shipping Seamonkey.
Comment 51 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-09-28 05:19:34 PDT
Nominating for rtm because of reasons stated in my previous comments. I can describe 

concrete authoring scenarios if necessary.
Comment 52 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-09-28 07:08:52 PDT
Agreed.  We need to fix this for rtm.  It is at the core of our standards
compliance.  We really should fix it for beta3 to get more testing, though...
Comment 53 Pierre Saslawsky 2000-09-28 07:47:20 PDT
Rick, this bug is marked "fix in hand". Is it for real, or is the remnant of a 
previous fix?
Comment 54 ekrock's old account (dead) 2000-09-28 12:40:48 PDT
David, Ian, Henri -- Please provide as much concrete data as possible about the 
severity of impact if we don't fix this. This is the data I must have in order 
to make a case to PDT for accepting a fix like this at this late date. Thanks!

Also, could someone please change the Summary from "Transitional DOCTYPE with 
URI considered quirky" which makes no sense (what's the problem? what's right? 
what's wrong? what should we do?) to a phrase that clearly states what is wrong 
and what must be done to fix it? 
Comment 55 ekrock's old account (dead) 2000-09-28 12:42:17 PDT
Also, please document that this is low-risk. (It should be, because we're just 
choosing which existing, tested code path gets applied in a particular 
situation, right?)
Comment 56 rickg 2000-09-28 17:18:02 PDT
As I understand the request, folks want Transitional docs to set the layout 
"mode" to be non-quirky. If that's the consensus, fine -- it's really a 
*trivial* fix. I expect 2 lines of code, and a bit-o-testing.
Comment 57 Pierre Saslawsky 2000-09-28 17:48:50 PDT
My main concern is still (and it used to be the original Summary line of this bug 
report) that documents with unknown doctypes are displayed in quirks mode. Look 
at my "testcase that should display in strict mode" (08/24/00 19:14): it uses the 
doctype from our good friend Todd Farhner at Verso's and it displays in quirks 
mode.

On [2000-08-29 17:04], Harish marked said that it would get fixed when bug 50070 
would be fixed and he marked it as dup, but bug 50070 is gone and the problem 
still remains.
Comment 58 rickg 2000-09-28 18:07:47 PDT
From your comment, it seems you want unknown doc types to be non-quirky. But 
that's not what 4x would do -- and it doesn't seem to be the original point of 
this bug. I think IE uses bugward compatibility (I'll double check). If they do, 
then I'd be disinclined to enter standard mode.  
Comment 59 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-09-28 18:12:14 PDT
Eh?  Netscape 4.x doesn't do DOCTYPE sniffing, and MacIE 5.0 uses the URI the way 
this bug suggests.
Comment 60 Pierre Saslawsky 2000-09-28 18:49:10 PDT
I'm not the best guy to talk about the whole issue but I understood as obvious 
from the experts that it is very important not to be quirky with unknown doctypes 
otherwise it would greatly impact the use of doctypes in the future.

Quirks mode should be triggered by the absence of doctype, or by the presence of 
a few doctypes that we think should be quirky.
Comment 61 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-09-29 08:41:39 PDT
Colors (all pages)

HTML 4 Strict doesn't allow any color definitions for the page. As a result, non-CSS 
browsers use a browser color scheme when displaying pages authored with HTML 4 
Strict and CSS.

The default page background color is typically gray in lecagy browsers. Web authors, in 
general, consider the default gray particularly ugly and also think that most users haven't 
changed the default.

Color is considered important. Even if the page was written to the standards and with 
(primarily) non-quirky rendering in mind, the author is still likely to want to include 
deprecated color definitions to get the intented color scheme in non-CSS browsers.


Floaters (nearly all pages with images)

Making the text wrap around images is a common design practice when images are 
displayed alongside text. This effect can be achieved by using floating images. Floating 
behavior can be controlled by using CSS or by using deprecated HTML. In the case of 
HTML 4 Strict, using CSS is the only option.

Pages with CSS-only floaters look particularly badly designed in non-CSS browsers. 
The user of such a browser might think the author has no skill or taste. The images make 
big gaps in the text, but the line following an image is next to the image instead of being 
entirely below the image. On the other hand, the look of such pages in non-CSS 
browsers can be significantly improved by using deprecated HTML as a fallback solution.

The author is likely want to include deprecated floater information even if the page was 
primarily intented for standards-compliant non-quirky display.


The solution

Note that in the above examples, the intent is not to make the page look identical in 
standards-compliant CSS browsers (including Mozilla) and in non-CSS browsers. The 
intent is not to have Mozilla handle the page the same way old browsers do. Rather, the 
intent is to leverage standard layout and new features in new browsers while still 
including some presentational hints for old browsers.

Since the Strict DTD doesn't allow the inclusion of such presentational hints, the 
Transitional doctype declaration has to used in order to keep the code valid. If Mozilla 
renders these pages in the quirks mode, the goal of leveraging standard rendering in 
new browsers isn't met.

This problem can be worked around in a way that is not standards-compliant. It would be 
better to discourage the use of non-compliant workarounds by providing a 
standards-compliant way to leverage the standard layout mode with pages that also 
contain presentational hints for older browsers. The solution would be triggering the 
standard layout mode for pages that contain a Transitional doctype declaration in full with 
the URI. (Note that pages generated by the Composer component of Communicator 4.x 
don't include a full doctype declaration with the URI and would still trigger the quirks 
mode.)

Not fixing this bug would significantly raise the treshold of migrating from quirks to 
standards.


Risk analysis

The fix involves a very slight change in the code that makes the decision about the layout 
mode. The fix isn't expected to affect the stability of Mozilla. 

In practice, the only risk is that some non-compliant pages that nonetheless use a 
Transitional doctype declaration in full with the URI might depend on quirky layout and 
show up in an unintended in the standard layout mode. This risk could be minimized by 
restricting the standard layout to HTML 4.01 (and the hypothetical "later") Transitional 
with the URI and unknown doctypes (as opposed to including HTML 4.0 Transitional with 
the URI).

Of the top sites that I have checked only apple.com uses the HTML 4.01 Transitional 
doctype declaration with the URI. Fixing this bug would cause a noticable but not fatal 
misalignment in the navigation bar at apple.com. However, I think the benefits that would 
come along fixing this bug by far more important than that misalignment. I think it is better 
to expect Apple to fix their site (very trivial to fix) instead of letting that small misalignment 
jeopardize the migration from quirks to standards layout.

(Note: Previous tests with rendering some Transitional documents in the standard layout 
mode involved a parser mode that had a very strict error handling policy. This is not the 
case with the current parser mode. That is, bug reports about the old parser mode 
shouldn't be held against using the standard layout mode with the current parser mode.)
Comment 62 Andreas Franke (gone) 2000-09-29 10:00:23 PDT
Rick, as I understand the request, docs with a Transitional doctype _with URI_
should set layout "mode" to be non-quirky. Is this possible? Is it an illusion
to think that there is still any chance to get this into PR3?

Changed summary from "considered quirky" to "should not be considered quirky".

What I'm concerned about is that shipping 6.0 without this fixed would make it
nearly impossible to fix it in a later release, or even a mozilla.org release,
just because 6.0 will be quoted as precedence.
Comment 63 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-01 05:35:54 PDT
Just summarizing my previous comments:

Let's consider these three propositions:
P1: Page looks great in Mozilla-based browsers
P2: Page looks at least reasonably good in legacy browsers
P3: Page validates

The way Mozilla currently is, only two of those three propositions can hold true for a 
[normal] page at a time. Considering past authoring practices and priorities, I think Web 
authors are likely to pick the combination where P1 and P2 are true while P3 is false. 
Wouldn't it be ironic, if the introduction of a browser that aspires to be 
standards-compliant would lead to an increase of pages that are declared as Strict but 
are deliberately not valid?

Fixing this bug would make it possible to have all the three propositions hold true at the 
same time. That's why I think fixing this bug (in the trunk and in the branch) would a very 
big win.
Comment 64 Andreas Franke (gone) 2000-10-01 08:02:48 PDT
Can someone *please* explicitly state that it is possible (and makes sense) to
fix this for later releases as suggested by the "Future" milestone? Otherwise
this has to be targeted for M18/RTM or marked WONTFIX.
Comment 65 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-01 08:30:33 PDT
It doesn't make sense to postpone fixing this past the Netscape RTM.

If any Mozilla-based browser gets distributed to a lot of people (like Netscape 6) without a 
standards-compliant way to trigger the standards layout for Transitional markup, the 
damage to standards-compliant authoring can't be retroactively fixed.
Comment 66 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-01 11:11:50 PDT
In reference to RickG's comment from 2000-09-28:
The intent is not to change all Transitional docs to standard layout. The intent is to trigger 
standard layout for Transitional documents whose doctype declaration contains the URI. 
If that is considered too risky for HTML 4.0 Transitional, even doing it for HTML 4.01 
Transitional would be *very very* important.

That is:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
would go to the quirks mode while
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
would go to the standards mode.
Comment 67 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-10-01 14:17:42 PDT
IMO, we should be triggering standard mode for any DOCTYPE declaration with a 
system ID (i.e., a URI).  (We should really be doing the FPI decisions based on a 
list of doctypes that are quirky, rather than the reverse.)

It would make sense to fix this after 6.0 ships if we don't fix it for 6.0.  It 
would just mean that authors would have to wait for 6.0 to drop to insignificant 
market share before writing standards-compliant pages just like they are now 
waiting for 4.x to drop off the market.  (I suspect 6.0 may drop off the market 
before 4.x does, since a 6.0 -> 6.1 upgrade should be rather painless.)  However, 
I still think we should fix it the right way for 6.0, although it does need some 
testing if we are going to do so, and it probably should have been done sooner so 
we could get more testing.  

We did agree to fix this before, but the fix was undone to fix bug 42388 in a 
very easy way right before beta2 (rather than just turning off the Strict/
Transitional DTD, as has been done since).  See the comments from 2000-08-11 when 
this bug was reopened.
Comment 68 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-03 06:12:09 PDT
As per jar's post to n.p.m.seamonkey, PDT won't be looking at this bug until this is 
[rtm+]'ed. Who, in this case, is the qualified person to give this bug the [rtm need info] 
status in order to allow working on a patch?

Does the [pdtp5] marking need to be removed from the status whiteboard? Does it cause 
this bug to fall off the reconsideration radar?
Comment 69 ekrock's old account (dead) 2000-10-04 14:57:38 PDT
First, many thanks to Henri for careful research & analysis and for escalating 
this. You've performed a real service for Gecko, Mozilla, Netscape 6, standards 
compliance, and enabling the actual use by web content authors of our 
standards-compliant layout. 


Clarifying the current meaning of this bug report
-------------------------------------------------
1) This bug report is not suggesting that we revisit the whole macro-level 
strict decision that was resolved earlier in a conference call; that's a dead 
snake.
2) Also, there's a second issue noted by Pierre, the proposal that our URI 
sniffing should handle unknown doctypes in strict mode (strict by default, 
quirks only for recognized exceptions) rather than quirks mode as it does 
currently. I haven't had the time to develop an opinion on that, but to focus 
this bug report, I will open a separate bug to track that issue.
3) Changing summary from "Transitional DOCTYPE with URI should not be considered 
quirky" to "Transitional DOCTYPE with URI should trigger strict layout mode." 
This bug report will now focus on this one issue only.


What this bug report is proposing
---------------------------------
If we implement this fix for RTM (and I believe that we should, for reasons 
noted below), then the following DOCTYPEs, which have the URI specified and 
currently trigger quirky *layout*, will trigger strict *layout* (not parsing) 
instead:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">

The following DOCTYPEs without the URI will continue to trigger quirks mode as 
they do now:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">


Why it's important to do this for RTM
-------------------------------------
1) As noted by Henri, the current inability to include presentational hints for 
older browsers (while still laying out strictly within Moz/N6) is a significant 
obstacle to web content authors who wish to take advantage of Gecko's hard-won 
standards compliance. Fixing this bug will solve that problem and will greatly 
enhance the ability of content developers to actually make use of the 
standards-compliant layout we worked so hard to achieve.
2) It's important to do this for RTM as opposed to a later point release because 
if we delay this change to a later point release, web content developers won't 
be able to take advantage of it until Netscape 6.0 drops to negligible market 
share, replaced by the point release.
3) Achieving standards compliance was one of the key strategic goals for the 
entire Gecko and Mozilla projects; removing blockers that prevent content 
authors from leveraging that standards compliance is critical to achieving 
success on the web.
4) This bug is important even if you're just looking at AOL's internal needs 
alone. Fixing this bug will significantly simplify the task of AOL online 
properties (and unaffiliated sites as well of course) who want to make sure they 
work well on Netscape 6; fixing this will significantly ease internal evangelism 
for Netscape 6 support throughout AOL online properties.

Marking P2 as this bug is critical to enabling high-profile web content 
properties, including those of AOL itself, to support and optimize ASAP for 
Gecko-based browsers such as Netscape 6 and Gecko-based devices such as the 
AOL/Gateway appliance. Clearing [pdtp5] to trigger re-evaluation.


Why this is low-risk
--------------------
a) This fix is low-risk with respect to destabilizing the Mozilla codebase. 
We're simply modifying our DOCTYPE sniffing rules to switch which existing 
layout approach is followed for a particular DOCTYPE.
b) This fix is also low-risk with respect to creating incompatibilities with 
existing web content. We know that IE5 for the Mac already shipped with this 
feature. Given the priority Microsoft places on backward compatibility, they 
would not have done this if they felt it would cause IE5 for Mac to display 
legacy content poorly.
c) I and/or the Mozilla evangelists will take care of evangelizing apple.com 
(the one known site with a problem here) to fix their markup.

Issues
------
1) We need an engineer who will write the patch, get it reviewed and 
super-reviewed, and check it in. Rick, the bug's currently assigned to you; 
could you do this? If yes, please confirm and mark [rtm+ need info]. If not, 
let's look for someone who is able to. Clearing fix in hand.
2) PDT needs to approve the check-in. I'll be happy to present to PDT team if 
necessary. Please mark rtm++ as soon as a fix is attached, reviewed, and 
super-reviewed, and call me if you're even considering marking this rtm-. 

Changing from FUTURE to M19. Thanks all!
Comment 70 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2000-10-04 16:14:55 PDT
I think the original idea was that all DOCTYPEs with a URI should trigger strict 
layout mode.  Does anybody object if I retitle the bug?  (The old title pointed 
to a specific symptom.  The new one attempts to describe the general problem but 
I think does not.)
Comment 71 Pierre Saslawsky 2000-10-04 18:00:07 PDT
I think that Rick wanted to trigger the quirks mode when we had no DOCTYPE at 
all, of course, but also when the DOCTYPE matched one of the few recognized ones 
like HTML 3.0. The original title was something like "Documents with unknown 
DOCTYPE should be displayed in strict mode".
Comment 72 ekrock's old account (dead) 2000-10-04 18:55:24 PDT
David--thanks for checking, *please* do not retitle this bug! We're going to 
keep this particular bug report focused on the simplest, lowest-risk case of 
"The HTML 4.0x Transitional DOCTYPE with URL should trigger strict layout mode." 
That is the least-controversial, lowest-risk thing being discussed here and the 
proposal PDT is most likely to accept given the limited time before ship. It's 
also probably the most important.

David and Pierre's proposals each may (or may not) be something we want to do 
for RTM, but each proposal affects a much larger class of documents than this 
proposed fix (David's proposal: all DOCTYPEs with a URI; Pierre's proposal: all 
unknown DOCTYPEs) and as a result *might* cause more backward compatibility 
problems since they're affecting the handling of more pages than this bug fix.

To keep this bug report focused, I have hived off two new bug reports to track 
David's and Pierre's proposals, which each need to get their own cost-benefit 
analysis and rtm++ or rtm- status distinct from what I did above for the simple 
case. Here they are:

David:  bug 55263: "all DOCTYPEs with a URI should trigger strict layout mode"
Pierre: bug 55264: "Documents with unknown DOCTYPE should be displayed in strict 
mode"

BTW, I recognize of course that depending upon the evaluation of David's and 
Pierre's proposals, we might want to make all the changes at once for 
efficiency. The point however is that I'm trying to get the cost-benefit 
analysis for each separate proposal (and rtm approval or denial status) 
contained within its own separate bug report, instead of mixed together in this 
one.
Comment 73 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-06 16:12:08 PDT
Clarification to my risk analysis which addressed HTML 4.01:
Implementing this for
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd"> is very safe.

Implementing this for <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> would, on some sites
(eg. www.sun.com, www.versiontracker.com), cause table cells whose content lower
than the line height (ie. small images) be sized vertically to the line height.
IE 5 for Mac gets around this. This might be addressable in the UA style sheet.
Comment 74 Hixie (not reading bugmail) 2000-10-06 17:34:20 PDT
MacIE5 gets around it by implementing the Inline Box Model incorrectly.
Comment 75 ekrock's old account (dead) 2000-10-10 13:15:54 PDT
Marking [DOCTYPE] for easy searching.
Comment 76 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-10 21:03:26 PDT
I think that at this point it would make sense to narrow this bug to apply only to 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd"> in order to avoid box sizing issues with sites that 
use <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">.

RickG, What's the situation with this bug?
Comment 77 Ben Bucksch (:BenB) 2000-10-11 19:02:50 PDT
Is RickG known to be aware of this bug and its current state?
Comment 78 Marc Attinasi 2000-10-12 10:43:15 PDT
Too much spam - removing self. Sorry for *my* spam.
Comment 79 Chris Petersen 2000-10-12 15:59:14 PDT
Requesting a triage on this bug. It's nominated but doesn't have a - or +. Are
we going to fix this for rtm ?
Comment 80 rickg 2000-10-12 16:06:08 PDT
I'm brutally aware the issue -- and I have a simple patch to correct. I'll add a 
patch that corresponds to henri's latest proposal, to do this only for the 
doctype (HTML 4.01 or greater):

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 
Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
Comment 81 Ben Bucksch (:BenB) 2000-10-12 16:16:36 PDT
MSIE5Mac uses strict rendering for the HTML 4.0(0) doctype with URI, right? If
we don't, we might cause troubles for pages that use this doctype to trigger
strict rendering (especially because MSIE5Mac shows this behaviour), not? Should
we file a bug about HTML4.00 specifically?
Comment 82 rickg 2000-10-12 16:49:44 PDT
We cant do that because nav4x/composer emited that doctype but expects backward 
compatible behavior. :(
Comment 83 Hixie (not reading bugmail) 2000-10-12 16:54:25 PDT
no, Nav4x Composer used an invalid doctype altogether (it was lowercase) and so
should not be an issue in deciding the resolution for this bug.
Comment 84 rickg 2000-10-12 18:02:22 PDT
Here's the patch which fixes this bug:

Index: nsParser.cpp
===================================================================
RCS file: /cvsroot/mozilla/htmlparser/src/nsParser.cpp,v
retrieving revision 3.225.2.1
diff -r3.225.2.1 nsParser.cpp
633a634
>
701a703,705
>   PRInt32 theMajorVersion=3;
>   PRInt32 theMinorVersion=0;
>
775d778
<                     PRInt32 theMajorVersion=3;
783c786
<                       else aBuffer.Mid(theNum,theVersionPos,3);
---
>                       else aBuffer.Mid(theNum,theVersionPos,4);
785a789,792
>                       if('.'==theNum[1]) {
>                         theNum.Cut(0,2);
>                         theMinorVersion=theNum.ToInteger(&theErr);
>                       }
828a836,838
>       else if((eDTDMode_transitional==thePublicID) && 
(eDTDMode_strict==theSystemID)) {
>         aParseMode=(4<=theMajorVersion) ? eDTDMode_strict : eDTDMode_quirks;

>       }
867c877
<       aParseMode=eDTDMode_quirks;
---
>       aParseMode=(0==theMinorVersion) ? eDTDMode_quirks: eDTDMode_strict;
875a886
>

Comment 85 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-12 21:32:34 PDT
RickG, Great! Thank you.

Could a qualified Netscape person, please, give this [rtm+] so that this gets on the PDT's 
radar?

Ben Bucksch, IE 5 for Mac indeed triggers its standard layout mode for HTML 4.0(0) 
Transitional with the URI. However, in the case where line-height hasn't been explicitly 
defined by the author, IE 5 for Mac uses the image height to size vertically the enclosing 
box of the image (the Nav 1.x way). This isn't exactly the way described in the CSS spec 
and, therefore, this trick isn't used in Mozilla's standard layout mode. I recommended 
excluding HTML 4.0(0) from the scope of this bug in order to avoid any panic related to 
table cells being sized "unlike the author intended" on existing pages.

OTOH, HTML 4.01 Transitional pages with the URI (like HTML 4 Strict) pages are 
currently *very* rare.
Comment 86 ekrock's old account (dead) 2000-10-13 09:27:26 PDT
Rick, could you please attach patch & get reviewed and super-reviewed? Then we 
can go to PDT.
Comment 87 rickg 2000-10-13 12:37:17 PDT
The patch was already attached; r=attinasi; sr=buster.
Comment 88 Andreas Franke (gone) 2000-10-13 16:44:49 PDT
Somehow I've managed to apply the patch by hand to the latest source tarball 
(mozilla-source.tar.gz  26063 Kb  Fri Oct 13 10:03:00 2000) from the trunk.

In case you want to try out the patch on linux without building mozilla, you can
download http://www.ags.uni-sb.de/~afranke/mozilla/42525/libhtmlpars.so
and just copy it into the components dir of a recent working mozilla
installation, as a replacement for the existing library. This should work at
least on Red Hat and SuSE linux, with todays nightly, M18 and Netscape PR3.
Comment 89 Phil Peterson 2000-10-13 17:05:24 PDT
rtm++
Comment 90 Blake Ross 2000-10-17 14:34:08 PDT
four days now since ++.  What's the holdup?  Let's get this in before it gets 
minused.
Comment 91 rickg 2000-10-17 15:28:51 PDT
Awaiting secondary review from harishd. I'll ping him again.
Comment 92 Jerry Baker 2000-10-17 18:14:39 PDT
Am I misunderstanding the intent of the W3C in creating the transitional 
doctype? It seems to me that the comments at the top of the DTD are saying that 
the transitional DTD is meant as something authors can use while waiting for CSS 
support from browsers to increase. Why would an author then want the browser to 
render their document in strict mode if they had specifically chosen not to by 
specifying a transitional DTD?
Comment 93 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-17 21:21:37 PDT
Jerry, I suppose that you didn't read my previous explanations above. I think fixing this 
bug is in accordance with the W3C's intent for HTML Transitional.

Summary of previous explanations:
During the transition period (hence the name Transitional) from presentational HTML to 
style sheets, authors will want to get the benefits of the standards-compliant layout model 
(in the browser that support it) before they are willing to drop support for old browsers 
entirely. The goal in that case is not to make the page look identical across browsers. 
Rather, the goal is to make the page look great in CSS browsers and reasonably good in 
non-CSS browsers. Moving directly to HTML Strict would (usually) cause the page look 
bad in non-CSS browsers which is unacceptable to many authors during the transition 
period. On the other hand, staying with quirks would mean not getting the benefits of the 
standards layout in new browsers. 

For example, an author might want to use mainly the features of non-deprecated HTML 
and CSS but then also include deprecated presentational hints about the page color 
scheme and about floating images.

The standards *layout mode* does not throw out deprecated code like (now removed) 
Strict *parser mode* did.

If you want to use the quirks mode, you can do that easily by not using the doctype 
declarations that trigger the standards layout mode. However, the are others who want to 
use the standard layout in Mozilla and still provide presentational hints for old browsers.
Comment 94 harishd 2000-10-18 10:20:39 PDT
I went through the patch with rickg yesterday ( 10/17/00 ). And everything looks
fine. But, forgot to update the bug with r= info. So, here it is

r=harishd.

Comment 95 Jason Eager 2000-10-18 15:03:00 PDT
*desperate whisper*

please check this in before the pdt rtm-'s it. please. please. please.

*end desperate whisper*
Comment 96 Jason Eager 2000-10-18 16:18:06 PDT
YAY..this just landed on the branch (4:15 PDT, 12:15 NZST) :-)

Thanks, harishd for landing and rickg for fixing.
Comment 97 rickg 2000-10-18 16:53:57 PDT
This bug, more than any other, scares me of being disparaged in the same breath 
(for the same reasons) as other (former) netscape employees.
Comment 98 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-19 11:19:47 PDT
Verified in
2000101908-MN6 Mac
2000101904-Mtrunk Mac
2000101821-Mtrunk Solaris Sparc

rickg, harishd, many thanks for fixing & landing. And many thanks to everyone who 
helped in getting this fixed.
Comment 99 Chris Petersen 2000-10-19 19:28:28 PDT
Hmm.. Apple's site ,which uses a transition 4.0.1, now has misaligned images in
it's navigation bar. Check out www.apple.com. Rick, Should I reopen this or
report a new bug ?
Comment 100 Ben Bucksch (:BenB) 2000-10-19 19:38:18 PDT
petersen, this is known, see above. File a bug in the Evangelization component.
Comment 101 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-10-19 20:44:06 PDT
Bug 57371 tracks the Apple issue.
Comment 102 Jerry Baker 2000-10-19 22:15:29 PDT
I imagine you may want to make one bug that will cover all the related reports 
you will get as a result of this decision. It will be better than having scores 
of bugs for each site that will inevitably get reported to be "broken".
Comment 103 Jacob Kjome 2000-11-01 07:03:49 PST
Can someone write an final summary of what the new behavior now is with all the doctypes?  For instance, how will doctypes for HTML 2 or 3.2 be handled?  How will all available doctypes of HTML 4.0 and 4.01 be handled?  How is XHTML handled with all available doctypes or without a any doctype?

Just want to get a clear and final answer rather than try to interperet what has been said previously.

Jake
Comment 104 Andreas Franke (gone) 2000-11-01 07:19:09 PST
http://lxr.mozilla.org/seamonkey/source/htmlparser/src/nsParser.cpp#579
is an overview about DTD handling. Is it up-to-date?
Comment 105 Jerry Baker 2000-11-01 07:25:43 PST
No it is not up to date. Mozilla was recently made to render HTML 4.01 
Transitional with a URI pointing to the loose.dtd in standards mode as well.
Comment 106 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2000-11-01 13:51:31 PST
SUMMARY
-------

* The handling of this doctype 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
and the hypothetical later ie.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.02 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
was changed.

* The changes are effective in builds from 2000-10-19 onwards

* Among others, no doctype, HTML 2.0, HTML 3.2 and these doctype declarations trigger 
the quirks layout mode:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">

* HTML 4.x Strict doctypes, XHTML 1.0 doctypes and this doctype
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
trigger the standards layout mode.

* XHTML served as text/html without a doctype declaration isn't "strictly conforming" and 
triggers the quirks layout mode.

* The metabug is bug 34662
* Minimal documentation is covered in bug 36045
* Comprehensive documentation is covered in bug 31932

Let's keep possible further discussion (eg. about XHTML details, ISO doctypes or content 
served as text/xml) off this bug report.
Comment 107 Fabian Guisset 2001-05-15 10:57:58 PDT
*** Bug 78076 has been marked as a duplicate of this bug. ***
Comment 108 David Baron :dbaron: ⌚️UTC+1 (busy September 14-25) 2001-10-01 15:36:52 PDT
I'm very close to undoing this fix -- see bug 98977 and duplicates.  The main
idea of our quirks mode decision is for identifying pages that didn't exist
before we had significant presence on the web.  Pages that trigger strict mode
through the fix for this bug and therefore have problems are becoming more common.
Comment 109 Scott A. Colcord 2001-10-01 19:23:05 PDT
David: Which doctypes in particular are you intending on changing?

I noted Marc Attinasi's comments in Bug 102412, where he suggests that

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">

should be rendered in quirks, and I strongly disagree.  If that doctype is
switched back to quirks, there will be no way to have a transitional document
rendered in standards mode.  This would disadvantage those who want to write
standards-compliant documents for the benefit of those who continue to write
nonconforming ones; this would seem to be contradictory to the goals of the
Mozilla project.  I believe that the more appropriate fix is Evangelism, to get
them to fix the broken code.

CCing attinasi to invite his comments.
Comment 110 Henri Sivonen (:hsivonen) (Not reading bugmail or doing reviews until 2016-09-26) 2001-10-01 21:08:18 PDT
dbaron, please, please avoid changing the standards-modeness of HTML 4.01
Transitional with the SYSTEM identifier. If there is no way to activate the
standards mode for transitional, the cost for adopting standards becomes too
high. Isn't the goal to help people move to standards?

The real issue is bug 22274. The line-height behavior with table cells is
completely counter-intuitive. If a compromise was made with bug 22274, there
would be not need to protect folks from the standards mode.

I know that you don't want to make any compromises with the standards mode, but
what's the point if using the standards mode becomes so difficult that almost no
one uses it?

BTW, I've seen more XHTML 1.0 Transitional pages breaking due to bug 22274 than
I have seen HTML 4.01 Transitional pages breaking due to bug 22274.

Also, Mac IE 5 and Windows IE 6 go into their respective standards mode for HTML
4.01 Transitional with the SYSTEM identifier. That is an attactive choice for
authors. If Mozilla goes into the quirks mode, then Mozilla will be the browser
that appears non-compliant and causes problems.

The problem is not the doctype. The problem is that a line box is generated when
a table cell contains only an image (with no non-white space).
Comment 111 Marc Attinasi 2001-10-02 13:18:33 PDT
I'm agnostic on this - mostly. If evangelism can solve our compatibility
problems while allowing us to do the 'right thing' from a standards perspective,
then that is great. Otherwise, we have the compatibility vs. standards religious
war on our hands.
Comment 112 Jacob Kjome 2001-10-02 14:53:29 PDT
Maybe an example would help.

We need at least one loose doctype to be rendered in Standards mode.  The one I 
have used is:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html401/loose.dtd">

I worked on a site where all the html I wrote would have been valid under the 
strict doctype, except for one area; setting the border on images.  I would 
have done this is css, but, as I found out, NN4.xx reacts in incredibly nasty 
ways when any attempt is made to set styles on images such as width, height, 
and border.  I also wanted to advertise the site as being valid and have the 
w3c html validator report no errors.  If I used the Strict doctype, I would get 
the following error:

Error: there is no attribute "BORDER" for this element (in this HTML version) 

However, using the Transitional doctype, I was able to avoid the error AND 
continue to have Mozilla/NN6.x (and presumably both IE6 and IE5 for Mac) 
display the page in standards mode while continuing to support NN4.xx (and 
IE5.x).

Now, this may seem incredibly trivial, but if it wasn't for the availability of 
a transitional doctype that could trigger standards mode, I wouldn't have been 
able to have nearly seamless support for all modern browsers, have them all 
display the page with a consistent look and feel, AND pass w3c html validation 
with zero errors!

The 4.01 Transitional doctype triggering Standards mode is pretty much a 
panacea for me.  Please don't take it away otherwise my efforts to support 
standards AND provide legacy support will be for naught!  Would you like to 
reward developers like me who sincerely try to support standards or the stupid 
bastards that wouldn't know a standard if it bit them in the ass?

jake
Comment 113 Scott A. Colcord 2001-10-25 20:49:07 PDT
I just found an MSDN link detailing exactly how IE6 and later do their DOCTYPE
checking, and a lot of the differences between their compliant and non-compliant
modes:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnie60/html/cssenhancements.asp
Comment 114 Jerry Baker 2002-05-27 14:25:26 PDT
Mass removing self from CC list.
Comment 115 Jerry Baker 2002-05-27 14:49:23 PDT
Now I feel sumb because I have to add back. Sorry for the spam.

Note You need to log in before you can comment on or make changes to this bug.