- From: Susan Lesch <lesch@w3.org>
- Date: Thu, 6 Apr 2000 00:04:25 -0800
- To: www-html-editor@w3.org
Nicholas R. Rinard wrote:
> I am having a problem with my DOCTYPE declaration and IE5
> Macinstoh Edition. When I specify my doctype as XHTML using a
> strick or transitional doctype declaration copied from the
> XHTML reccomendation (http://www.w3.org/TR/xhtml1/) my pages
> fail to render correctly.
You have empirically discovered a major departure from Mac IE 4.5.1.
To handle both valid pages and those with markup errors, MacIE 5.0's
new rendering engine has two modes, "strict" and "compatibility." It
renders using one or the other based on DOCTYPEs. The only place I
have seen this mentioned so far is in Microsoft's interview with Todd
Fahrner [1].
> Specifically, I use the tag <<div class="center"> to center
> elements on many of my pages (which resolves in my CSS to
> "text-align: center;"). If I specify no DTD or an HTML4 DTD
> everything is fine, but when I specify an XHTML DTD the tag
> seems to be ignored.
Yes. If you want the backward "compatibility" mode, either use no
DOCTYPE, the HTML 2 to 3.2 or the HTML 4 or 4.01 Transitional
DOCTYPE, and do not include any reference to a DTD.
[snip]
> PS The site is at
>
> http://www.dartmouth.edu/~nrrinard/
Despite earlier MacIEs' behavior, CSS2 says 'text-align' should apply
only to the inline contents [2] of block level elements. To produce
the desired effect in "strict" mode, change from "text-align:
center;" to positioning [3], something like:
.center {
position: relative; left: 10%; width: 80%;
}
Disclaimer: I got this centering problem wrong twice during the
MacIE5 beta test, and I suggest that you ask Microsoft for
clarification on both it and the new rendering modes. There are two
good places to try. Subscribe to the Mac IE Talk list by sending mail
to <MacIE-Talk-on@lists.boingo.com> or post to the newsgroup
<microsoft.public.inetexplorer.mac>.
[1] http://www.microsoft.com/mac/IE/Testimonials/fahrner.asp
[2] http://www.w3.org/TR/REC-CSS2/text.html#propdef-text-align
[3] http://www.w3.org/TR/REC-CSS2/visuren.html#relative-positioning
By the way, www-html-editor is for feedback to editors. You might
want to keep in mind the newsgroup
<comp.infosystems.www.authoring.html> for authoring questions and the
www-html list for questions and feedback on the HTML and XHTML
specifications.
Best wishes,
--
Susan Lesch
Intern, W3C
Received on Thursday, 6 April 2000 03:04:08 UTC