Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Alastair Campbell

On 5/25/07, David Dorward [EMAIL PROTECTED] wrote:

Not causing validation issues does not make them fine; even if the
vast majority of user agents don't respect it, img / in an HTML
document means An image element followed by a greater than sign.
The HTML specification explicitly advises authors to avoid them:
http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7


Interesting, but I don't understand how that section applies?

How do you get from these constructs technically introduce no
ambiguity in that section, to a self-closed image being An image
element followed by a greater than sign?

Especially since this case is explicitly shown in the compatibility
guidelines (http://www.w3.org/TR/xhtml1/#C_2).

Is Vlad from Xstandard wrong when he said: if an authoring tool
generates XHTML in a backwards compatible way, then there is no need
to have a configuration to produce either HTML or XHTML. The
backwards compatible XHTML will work in HTML and XHTML templates.
(http://alastairc.ac/2007/02/wysiwyg-editor-spec-checklist/#comment-12741 )

Or is this a case of it doesn't quite comply to part of a spec but
doesn't make any difference in practice? If it isn't, perhaps the
W3C's HTML validator should be updated?

Cheers,

-Alastair


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread David Dorward


On 29 May 2007, at 12:50, Alastair Campbell wrote:


On 5/25/07, David Dorward [EMAIL PROTECTED] wrote:

Not causing validation issues does not make them fine; even if the
vast majority of user agents don't respect it, img / in an HTML
document means An image element followed by a greater than sign.
The HTML specification explicitly advises authors to avoid them:
http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7


Interesting, but I don't understand how that section applies?

How do you get from these constructs technically introduce no
ambiguity in that section, to a self-closed image being An image
element followed by a greater than sign?


Because, in an HTML document, an XHTML style img tag unambiguously  
means An image element followed by a greater than sign.




Especially since this case is explicitly shown in the compatibility
guidelines (http://www.w3.org/TR/xhtml1/#C_2).



... because most browsers don't support img / correctly in HTML  
documents, you can write XHTML documents that are compatible with  
most HTML user agents (this is not the same as being compatible with  
HTML).



Is Vlad from Xstandard wrong when he said: if an authoring tool
generates XHTML in a backwards compatible way, then there is no need
to have a configuration to produce either HTML or XHTML. The
backwards compatible XHTML will work in HTML and XHTML templates.
(http://alastairc.ac/2007/02/wysiwyg-editor-spec-checklist/ 
#comment-12741 )


Depends on your definition of work. It renders as the author  
intends in most HTML user agents. It doesn't mean what the author  
intends in anything that parses the HTML correctly.



Or is this a case of it doesn't quite comply to part of a spec but


No. The spec allows img /, it just means something different.


doesn't make any difference in practice?


W3 used to parse the construct correctly under HTML rules (when I  
used it from time to time). Since then, I think they have crippled  
its HTML handling to cope with the amount of bad markup out there.



If it isn't, perhaps the
W3C's HTML validator should be updated?


Anywhere an img element is allowed in an HTML document, a greater  
than sign is also allowed. So the construct is valid and the  
validator should not claim otherwise. It just doesn't mean what the  
author intends.


--
David Dorward
http://dorward.me.uk/
http://blog.dorward.me.uk/




***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Andrew Maben

On May 29, 2007, at 9:26 AM, David Dorward wrote:
Because, in an HTML document, an XHTML style img tag unambiguously  
means An image element followed by a greater than sign.


Sorry to be dense, I'm trying to grasp this concept. Does (at least  
strictly speaking) the inclusion of a forward slash within the tag of  
any element prevent the tag in question from being terminated? I  
guess my question is how a tag that has not been terminated (with  
) can be said to be followed by anything at all?


And further:

... because most browsers don't support img / correctly in HTML  
documents


How is img / (or presumably br /) correctly supported? And which  
browsers do correctly support it?


Thanks,

Andrew

109B SE 4th Av
Gainesville
FL 32601

Cell: 352-870-6661

http://www.andrewmaben.com
[EMAIL PROTECTED]

In a well designed user interface, the user should not need  
instructions.









***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***

Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread David Dorward


On 29 May 2007, at 14:55, Andrew Maben wrote:


On May 29, 2007, at 9:26 AM, David Dorward wrote:
Because, in an HTML document, an XHTML style img tag unambiguously  
means An image element followed by a greater than sign.


Sorry to be dense, I'm trying to grasp this concept. Does (at least  
strictly speaking) the inclusion of a forward slash within the tag  
of any element prevent the tag in question from being terminated?


No. A forward slash terminates the tag (so the  character is outside  
the tag, so its character data).


In HTML all these mean the same thing:

img /
img
imggt;

(and title/ foo / means the same as title foo /title)



... because most browsers don't support img / correctly in HTML  
documents


How is img / (or presumably br /) correctly supported? And  
which browsers do correctly support it?


An image (or line break) followed by a  character.  So Hellobr / 
World should be rendered:


Hello
World

(in HTML).

The only browser I know of, off the top of my head, that gets it  
right is W3 (and as mentioned, I believe it was intentionally  
crippled to cope with fallout from Appendix C). Of course nsgmls and  
related programs also get it right.



--
David Dorward
http://dorward.me.uk/
http://blog.dorward.me.uk/




***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Alastair Campbell

On 5/29/07, David Dorward [EMAIL PROTECTED] wrote:

Because, in an HTML document, an XHTML style img tag unambiguously
means An image element followed by a greater than sign.


I still can't see where it says that in the spec, do you need to know
the SGML spec as well? It seems strange that the closing slash is
taken as the close, rather than the greater than sign, is that in the
HTML spec somewhere?

Since this is either ill defined or not defined in the HTML spec so
far (unless WHATWG tackled it?), I'd suggest that the method implied
by XHTML compatibility guidelines might be a more suitable reference
in future?


the construct is valid and the
validator should not claim otherwise. It just doesn't mean what the
author intends.


Given the mis-match in meaning that does not produce an error, surely
it's something that should change then?

Kind regards,

-Alastair


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Rimantas Liubertas

I still can't see where it says that in the spec, do you need to know
the SGML spec as well? It seems strange that the closing slash is
taken as the close, rather than the greater than sign, is that in the
HTML spec somewhere?


http://www.w3.org/TR/html401/sgml/sgmldecl.html
FEATURES, SHORTTAG YES

...
Regards,
Rimantas
--
http://rimantas.com/


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Alastair Campbell

On 5/29/07, Rimantas Liubertas [EMAIL PROTECTED] wrote:

http://www.w3.org/TR/html401/sgml/sgmldecl.html
FEATURES, SHORTTAG YES


I guess from that I should deduce that I do need to know the SGML spec
to know that a slash will terminate a tag?

I hope HTML5 does away with this...

-Alastair


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Nick Fitzsimons

On 29 May 2007, at 16:14:53, Alastair Campbell wrote:


On 5/29/07, David Dorward [EMAIL PROTECTED] wrote:

Because, in an HTML document, an XHTML style img tag unambiguously
means An image element followed by a greater than sign.


I still can't see where it says that in the spec, do you need to know
the SGML spec as well?


Yes, HTML is an SGML application, as described in the spec:
http://www.w3.org/TR/html4/intro/sgmltut.html#h-3.1

Therefore a compliant parser must parse according to the rules of SGML.

The spec does include an appendix:
http://www.w3.org/TR/html4/appendix/notes.html#sgmlfeatures
listing aspects of SGML that are poorly supported by existing user  
agents; however, that doesn't excuse or justify improper behaviour by  
parsers, and the entire appendix is informative, not normative.


The specific SGML SHORTTAG construct under discusssion in this thread  
is included in the appendix at

http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7

Cheers,

Nick.
--
Nick Fitzsimons
http://www.nickfitz.co.uk/





***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread liorean

On 29/05/07, Alastair Campbell [EMAIL PROTECTED] wrote:

On 5/29/07, David Dorward [EMAIL PROTECTED] wrote:
 Because, in an HTML document, an XHTML style img tag unambiguously
 means An image element followed by a greater than sign.



I still can't see where it says that in the spec, do you need to know
the SGML spec as well?


Just in the same way you can't know XHTML if you have no knowledge of
XML, you can't really know HTML 2-4.01 with no knowledge of SGML. You
don't need to know all of SGML however, just the subset that is used
for HTML.


It seems strange that the closing slash is
taken as the close, rather than the greater than sign, is that in the
HTML spec somewhere?


Yes, in the SGML declaration.


Since this is either ill defined or not defined in the HTML spec so
far (unless WHATWG tackled it?), I'd suggest that the method implied
by XHTML compatibility guidelines might be a more suitable reference
in future?


Or the mechanism specified in the HTML 5 draft. But that's not even a
WD yet, so it'll have to wait.


 the construct is valid and the
 validator should not claim otherwise. It just doesn't mean what the
 author intends.

Given the mis-match in meaning that does not produce an error, surely
it's something that should change then?


HTML 5 will change it by no longer specifying that HTML is SGML.



And just for fun, let me give you an example of three documents:
uri:http://liorean.net/samplelayout.html
uri:http://liorean.net/sgml-goodness.html
uri:http://liorean.net/xhtmllayout.xhtml

All of them are valid documents and except for DOCTYPE, XML prologue
and XHTML namespace the document they describe is identical.
--
David liorean Andersson


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Alastair Campbell

Thanks Liorean,

On 5/29/07, liorean [EMAIL PROTECTED] wrote:

Just in the same way you can't know XHTML if you have no knowledge of
XML, you can't really know HTML 2-4.01 with no knowledge of SGML. You
don't need to know all of SGML however, just the subset that is used
for HTML.

 It seems strange that the closing slash is
 taken as the close, rather than the greater than sign, is that in the
 HTML spec somewhere?

Yes, in the SGML declaration.


Which someone linked to earlier, and I still can't translate to see
anything on forward slashes... is there actually an SGML spec? You'd
have thought it would be linked to from here:
http://www.w3.org/TR/html4/intro/sgmltut.html
or googlable with SGML spec, but no such luck.

Cheers,

-Alastair


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***




Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Nick Fitzsimons

On 29 May 2007, at 17:32:08, Alastair Campbell wrote:


 It seems strange that the closing slash is
 taken as the close, rather than the greater than sign, is that  
in the

 HTML spec somewhere?

Yes, in the SGML declaration.


Which someone linked to earlier, and I still can't translate to see
anything on forward slashes... is there actually an SGML spec? You'd
have thought it would be linked to from here:
http://www.w3.org/TR/html4/intro/sgmltut.html
or googlable with SGML spec, but no such luck.


The SGML spec is ISO 8879:1986, but being ISO, they charge a fortune  
for you to see it :-(


The topic under discussion is, as I mentioned in my earlier post,  
mentioned in HTML 4.01 at

http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7
as being something with poor support in HTML user agents.

Regards,

Nick.
--
Nick Fitzsimons
http://www.nickfitz.co.uk/





***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread liorean

On 29/05/07, Alastair Campbell [EMAIL PROTECTED] wrote:

On 5/29/07, liorean [EMAIL PROTECTED] wrote:
  It seems strange that the closing slash is
  taken as the close, rather than the greater than sign, is that in the
  HTML spec somewhere?
 Yes, in the SGML declaration.
Which someone linked to earlier, and I still can't translate to see
anything on forward slashes... is there actually an SGML spec?


Yes. Linking it probably won't help you though. You'll soon understand why:
http://www.iso.org/iso/en/CatalogueDetailPage.CatalogueDetail?CSNUMBER=16387scopelist=

More useful would be the SGML Handbook or some summary site, such as
uri:http://xml.coverpages.org//sgmlsyn/contents.htm


You'd
have thought it would be linked to from here:
http://www.w3.org/TR/html4/intro/sgmltut.html
or googlable with SGML spec, but no such luck.


Well, I got more than enough matches on SGML and Standard.
--
David liorean Andersson


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Alastair Campbell

On 5/29/07, Nick Fitzsimons [EMAIL PROTECTED] wrote:

The topic under discussion is, as I mentioned in my earlier post,
mentioned in HTML 4.01 at
http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7
as being something with poor support in HTML user agents.


Which I read, thank you, but unless I'm being particularly thick
(quite possible, it was a long weekend ;), I can't see how that
affects terminating characters. Without the SGML spec, what is a NET
character? It's just frustrating not to be able to get to the source
and find out what these things are.

Further googling lead to these which actually explain the issue, so
for anyone else who was confused:
http://www.rikkertkoppes.com/thoughts/2005/01/27/
http://lachy.id.au/log/2005/04/xhtml-future

Cheers,

-Alastair


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Lachlan Hunt

Alastair Campbell wrote:

On 5/29/07, Rimantas Liubertas [EMAIL PROTECTED] wrote:

http://www.w3.org/TR/html401/sgml/sgmldecl.html
FEATURES, SHORTTAG YES


I guess from that I should deduce that I do need to know the SGML spec
to know that a slash will terminate a tag?

I hope HTML5 does away with this...


HTML5 disposes of the myth that HTML is an application of SGML, so you 
don't need to understand SGML at all.  In fact, in HTML5, the trailing 
slash is explicitly permitted for void elements, though it's not 
necessary.  Void elements (formerly known as empty elements in SGML) are 
elements like br, img, meta, etc.


Thus, in HTML5, both img and img/ are permitted and mean the same 
thing.  The slash is ignored by the parser.  However, the slash is not 
permitted for non-empty elements.  e.g. p/ is not allowed in HTML, 
though it is in XHTML because XML rules apply.


--
Lachlan Hunt
http://lachy.id.au/


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***



Re: self-closing tags in HTML, was: [WSG] A CMS for POSH sites?

2007-05-29 Thread Lachlan Hunt

Alastair Campbell wrote:

On 5/29/07, Nick Fitzsimons [EMAIL PROTECTED] wrote:

The topic under discussion is, as I mentioned in my earlier post,
mentioned in HTML 4.01 at
http://www.w3.org/TR/html4/appendix/notes.html#h-B.3.7
as being something with poor support in HTML user agents.


Which I read, thank you, but unless I'm being particularly thick
(quite possible, it was a long weekend ;), I can't see how that
affects terminating characters. Without the SGML spec, what is a NET
character? It's just frustrating not to be able to get to the source
and find out what these things are.


SGML and HTML Explained by Martin Bryan [1] will explain everything you 
need to know about SGML.  In particular, chapter 4 explains the SHORTTAG 
NET features.  Figure 4.4 [2] lists the default delimiter characters 
from the reference concrete syntax, which includes:


   / NET Null end-tag

That can be set in the SGML declaration, but because it's not explicitly 
set in HTML4, it uses the default.


[1] http://www.is-thought.co.uk/book/
[2] http://www.is-thought.co.uk/book/sgml-4.htm#Fig4-4

--
Lachlan Hunt
http://lachy.id.au/


***
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: [EMAIL PROTECTED]
***