HighDots Forums  

Making HTML 4.1 Also Comply with XHTML 1.1

HTML Writing HTML for the Web (comp.infosystems.www.authoring.html)


Discuss Making HTML 4.1 Also Comply with XHTML 1.1 in the HTML forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ben Sharvy
 
Posts: n/a

Default Making HTML 4.1 Also Comply with XHTML 1.1 - 08-29-2003 , 03:37 PM






Is there a list of the changes you need to make to HTML 4.1 cose to
make it dual compliant, with XHTML 1.1 also?

Reply With Quote
  #2  
Old   
Headless
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 08-29-2003 , 04:54 PM






Ben Sharvy wrote:

Quote:
Is there a list of the changes you need to make to HTML 4.1 cose to
make it dual compliant, with XHTML 1.1 also?
Not possible.


Headless

--
Email and usenet filter list: http://www.headless.dna.ie/usenet.htm


Reply With Quote
  #3  
Old   
Jukka K. Korpela
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 08-29-2003 , 05:52 PM



Headless <me (AT) privacy (DOT) net> wrote:

Quote:
Is there a list of the changes you need to make to HTML 4.1 cose to
make it dual compliant, with XHTML 1.1 also?

Not possible.
Apparently not, since there is no HTML 4.1. :-)

Assuming the OP really meant 4.01, despite writing twice 4.1,
the answer is indeed the same, though for a different reason.

But is there some _other_ reason than the different requirements on the
<!DOCTYPE> declaration that prevent "dual compliance" to the two
specifications? This is of course pretty theoretic, and I wonder why the
question was asked. (Browsers play by their own rules, and virtually all
browsers claimed to comply with HTML 4.01 actually fail compliance in
several ways, and compliance to XHTML 1.1 is hardly even a good joke.)

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html



Reply With Quote
  #4  
Old   
Ben Sharvy
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 12:39 AM



"Jukka K. Korpela" <jkorpela (AT) cs (DOT) tut.fi> wrote


Quote:
But is there some _other_ reason than the different requirements on the
!DOCTYPE> declaration that prevent "dual compliance" to the two
specifications?
The <!DOCTYPE> declaration is neither HTML nor XHTML, so it is
irrelevant to the question.

Put another way, is there a markup that allows the *option* of
(validly) declaring it to be either HTML or XHTML.


Reply With Quote
  #5  
Old   
Jukka K. Korpela
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 01:32 AM



bsharvy (AT) mac (DOT) com (Ben Sharvy) wrote:

Quote:
But is there some _other_ reason than the different requirements on
the <!DOCTYPE> declaration that prevent "dual compliance" to the two
specifications?

The <!DOCTYPE> declaration is neither HTML nor XHTML, so it is
irrelevant to the question.
Both HTML and XHTML specifications make a <!DOCTYPE> declaration a
mandatory part of an HTML or XHTML document. In fact this follows from the
metalanguage (SGML and XML) rules. Ref.:

"For the sake of brevity, most of the examples in this specification do
not begin with the document type declaration that is mandatory at the
beginning of each HTML document."
http://www.w3.org/TR/html4/conform.html#h-4.2

"A Strictly Conforming XHTML Document - - must meet all of the following
criteria: - -
4. There must be a DOCTYPE declaration in the document prior to the root
element."
http://www.w3.org/TR/xhtml1/#normative
(And the only conformance it defines is being "Strictly Conforming"!)

The <!DOCTYPE> declaration is clearly defined as being _part_ of a
document. Note the wording "at the beginning", not "before" in the first
quotation, and "in the document" in the latter.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html



Reply With Quote
  #6  
Old   
Darin McGrew
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 03:05 AM



Owen Jacobson <ojacobson.usenet (AT) mx-deus (DOT) net> wrote:
Quote:
I think he's got the point now. I think what he's asking is whether
it's possible/convenient to author a document that, with a one-line
change to the DOCTYPE, can be either XHTML 1.0 or HTML 4.01.

My own take is fairly simple: yes, it's possible, and it's not even
that hard as long as you stick to semantic/logical markup rather than
trying to use TABLE for visual layout.
You must also avoid empty elements (e.g., LINK, IMG) that cannot be
represented in a way that is valid for both HTML and XHTML.
--
Darin McGrew, darin (AT) TheRallyeClub (DOT) org, http://www.TheRallyeClub.org/
A gimmick car rallye is not a race, but a fun puzzle testing your
ability to follow instructions. Upcoming gimmick car rallye in
Silicon Valley: Harry Potter & the Order of the Precedence (Sat, Sept 6)


Reply With Quote
  #7  
Old   
Matthias Gutfeldt
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 05:00 AM



Owen Jacobson wrote:
Quote:
Jukka K. Korpela wrote:


rather a lot snipped


I think he's got the point now. I think what he's asking is whether
it's possible/convenient to author a document that, with a one-line
change to the DOCTYPE, can be either XHTML 1.0 or HTML 4.01.

My own take is fairly simple: yes, it's possible, and it's not even
that hard as long as you stick to semantic/logical markup rather than
trying to use TABLE for visual layout.
No, tables for layout have nothing to do with it.


Matthias



Reply With Quote
  #8  
Old   
Chris Morris
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 08:41 AM



"Owen Jacobson" <ojacobson.usenet (AT) mx-deus (DOT) net> writes:
Quote:
Jukka K. Korpela wrote:
rather a lot snipped

I think he's got the point now. I think what he's asking is whether
it's possible/convenient to author a document that, with a one-line
change to the DOCTYPE, can be either XHTML 1.0 or HTML 4.01.

My own take is fairly simple: yes, it's possible,
Provided you use _no_ empty elements or are happy to rely on browsers
not following the relevant SGML rules on <element />.

Quote:
and it's not even that hard as long as you stick to semantic/logical
markup rather than trying to use TABLE for visual layout.
That would be a Strict / Transitional issue rather than an XHTML/HTML
issue, as far as I know. And yes, if the document is valid Strict it
can be served as valid Transitional [1], should you ever want to.

[1] With a doctype change, obviously.

--
Chris


Reply With Quote
  #9  
Old   
Darin McGrew
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 03:28 PM



I wrote:
Quote:
You must also avoid empty elements (e.g., LINK, IMG) that cannot be
represented in a way that is valid for both HTML and XHTML.
Owen Jacobson <ojacobson.usenet (AT) mx-deus (DOT) net> wrote:
Quote:
Oof. I missed that completely. Yeah, that's a big issue. For my own
information, is the following valid in XHTML 1.0? In HTML 4.01?

link rel="stylesheet" href="pagestyle" type="text/css"></link
In HTML, the closing </link> is invalid. You're trying to close a LINK
element that isn't open.

In XHTML, your example is valid, and is equivalent to

<link rel="stylesheet" href="pagestyle" type="text/css" />

(which is what Appendix C recommends).
--
Darin McGrew, mcgrew (AT) stanfordalumni (DOT) org, http://www.rahul.net/mcgrew/
Web Design Group, darin (AT) htmlhelp (DOT) com, http://www.HTMLHelp.com/

"I used to do lots of dumb things, but I turned my life around 360 degrees!"


Reply With Quote
  #10  
Old   
Stan Brown
 
Posts: n/a

Default Re: Making HTML 4.1 Also Comply with XHTML 1.1 - 09-02-2003 , 09:41 PM



In article <bj2r0e$8eb$1 (AT) blue (DOT) rahul.net> in
comp.infosystems.www.authoring.html, Darin McGrew
<mcgrew (AT) stanfordalumni (DOT) org> wrote:
Quote:
Owen Jacobson <ojacobson.usenet (AT) mx-deus (DOT) net> wrote:
Oof. I missed that completely. Yeah, that's a big issue. For my own
information, is the following valid in XHTML 1.0? In HTML 4.01?

link rel="stylesheet" href="pagestyle" type="text/css"></link

In HTML, the closing </link> is invalid. You're trying to close a LINK
element that isn't open.

In XHTML, your example is valid, and is equivalent to
<link rel="stylesheet" href="pagestyle" type="text/css" /
(which is what Appendix C recommends).
Now I'm confused. (This seems to be happening a lot lately.) I
understand that </link> is no valid HTML. But I thought the whole
point of Appendix C was to write markup that was valid HTML and
valid XHTML. The very first sentence of Appendix C is "This appendix
summarizes design guidelines for authors who wish their XHTML
documents to render on existing HTML user agents." True, that
doesn't say that the XHTML is valid HTML, but I thought that was
implied.

Are you saying that
Quote:
<link rel="stylesheet" href="pagestyle" type="text/css" /
is _not_ valid HTML?

--
Stan Brown, Oak Road Systems, Cortland County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2 spec: http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator: http://jigsaw.w3.org/css-validator/


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.