SitePoint Sponsor

User Tag List

Page 2 of 3 FirstFirst 123 LastLast
Results 26 to 50 of 60
  1. #26
    Resident curmudgeon bronze trophy gary.turner's Avatar
    Join Date
    Jan 2009
    Location
    Dallas
    Posts
    990
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by samanime View Post
    If you have a purpose for XHTML, then you will need to be careful.
    How is that different from marking up any page in any semantic or structural markup language? Aren't you careful to use correct syntax?

    However, 99% of people using XHTML now use it "just because", not making use of any of the advantages it has over HTML. In these cases, XHTML is a very bad choice.
    How so? The best even Hixie (Ian Hickson) can do is talk about coder incompetence and obscure edge cases. (Sending XHTML as text/html Considered Harmful) What reasons do you have?

    For example, Wordpress serves as XHTML by default. I love Wordpress, but this is a very bad move on their part (which is why I always force my templates into HTML). They make use of nothing special that XHTML can do, they just made it XHTML because that was what everyone else thought was "professional" to use.
    Orthogonal to the question at hand.

    cheers,

    gary
    Anyone can build a usable website. It takes a graphic
    designer to make it slow, confusing, and painful to use.

    Simple minded html & css demos and tutorials

  2. #27
    SitePoint Wizard Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,276
    Mentioned
    50 Post(s)
    Tagged
    2 Thread(s)
    Felgall, I thought when you checked your invalid XHTML page in IE9, it rendered the page (instead of showing an error). Or does it depend on a setting??

    Wordpress: wordpress doesn't send anything as XHTML, it just uses the hipper doctype. Two different things. XHTML doctype and /> everywhere != XHTML so I don't see the issue. I agree with Gary: if you are using XHTML because you need it, then your setup is going to be ok with the draconian error handling. All the whinging from Mark Pilgrim was highly entertaining, but he was talking about situations that had no reason or need to be XHTML (there were no XML documents being stored, manipulated by software who also needed to be presented as web pages).

  3. #28
    SitePoint Wizard
    Join Date
    Dec 2003
    Location
    USA
    Posts
    2,582
    Mentioned
    29 Post(s)
    Tagged
    0 Thread(s)
    I'm saying that if you are going to have someone else (a non-coder) editting content (which is very very very common in the real world), then it needs to be resistant to minor markup mistakes.

    As for Wordpress, I agree that it isn't really XHTML, but it does use that DOCTYPE. I do a replace to get rid of the />s, so it becomes valid HTML.

  4. #29
    Resident curmudgeon bronze trophy gary.turner's Avatar
    Join Date
    Jan 2009
    Location
    Dallas
    Posts
    990
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    And, I'm saying that which syntax you use, either html or xhtml, just doesn't matter if you're serving up text/html.

    If you're serving application/xhtml+xml, that unqualified, untrained and incompetent non-coder type person has no business touching the markup. He, she, or your pet monkey has no business editing your javascript, PHP, or database queries either.

    gary
    Anyone can build a usable website. It takes a graphic
    designer to make it slow, confusing, and painful to use.

    Simple minded html & css demos and tutorials

  5. #30
    SitePoint Wizard
    Join Date
    Dec 2003
    Location
    USA
    Posts
    2,582
    Mentioned
    29 Post(s)
    Tagged
    0 Thread(s)
    The point is though: why use XHTML if you're gonna serve it as text/html? That defeats the purpose entirely...

  6. #31
    SitePoint Enthusiast abdussamad's Avatar
    Join Date
    May 2006
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    As has already been pointed out you do it to follow the latest trend. At least what used to be the latest trend. The current latest trend is for HTML 5. So now we all have to unlearn the XHTML stuff and learn the HTML stuff. Does that mean I have to type my tags in uppercase now?

    Seriously no one cares. Was just going through the theme guidelines for the website baker CMS. The guidelines were made in 2008 and they require that all themes be XHTML 1.0 transitional. Whatever works I say. The burden is on browser developers to render everything perfectly!

  7. #32
    Resident curmudgeon bronze trophy gary.turner's Avatar
    Join Date
    Jan 2009
    Location
    Dallas
    Posts
    990
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by samanime View Post
    The point is though: why use XHTML if you're gonna serve it as text/html? That defeats the purpose entirely...
    I have already told you why I use xhtml syntax, and since either xhtml or html syntax is compatible as text/html, I see no compelling reason to change. HTML5 specifically allows either syntax. Since it doesn't make any difference, just what purpose is being defeated? So what if you don't use all its features. Just because you don't use all its capabilities doesn't mean you chuck xhtml. You don't dump your car because it will go faster than the speed limit, right?

    This thread is officially giving me tired-head. I'm done.

    gary
    Anyone can build a usable website. It takes a graphic
    designer to make it slow, confusing, and painful to use.

    Simple minded html & css demos and tutorials

  8. #33
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    I'd have to mainly agree with Gary even Fred 'text/html' allows the closing slash on void elements. Hence no major difference between an author that writes that in Fred, or an author that writes 'vanilla' XHTML 1.0 Transitional 'grammar' being sent to the legacy HTML user agent. Both may contain slashes. The fun only starts when the XML parser is running, which is NOT a requirement of vanilla Transitional.

  9. #34
    SitePoint Wizard Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,276
    Mentioned
    50 Post(s)
    Tagged
    2 Thread(s)
    abdussamad: I think you represent the general coder, who just wants to get stuff done... this argument here though is the validator nitpicking we like to do now and then for the sake of... just because : )

    To anyone: so, IE9 shows an error, or not? when presented with a true (sent as application xhtml+xml) XHTML page with an error?

    I'd like to know for certain what IE9 does with an invalid XHTML page, since I've heard conflicting things.

    I'm rather unhappy that I cannot test IE9 myself.

  10. #35
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    I tested it in Internet Explorer 9. It is able to handle the application/xml MIME type, but it incorrectly continues to render the page upon encountering an error. Chrome correctly stops rendering the page. Therefore, Internet Explorer 9 is not really XHTML compatible, but apparently accepts the MIME type, and then converts it to text/html.

    XHTML Test Page
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  11. #36
    ¬.¬ shoooo... silver trophy logic_earth's Avatar
    Join Date
    Oct 2005
    Location
    CA
    Posts
    9,013
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    The XHTML 1.0 specs do not state the user agent has to spit out an error or break on an error.
    Logic without the fatal effects.
    All code snippets are licensed under WTFPL.


  12. #37
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    I would have sent: 'application/xhtml+xml' like on my site. Though you have to fiddle with the settings I believe to get [IE9] to show errors http://blogs.msdn.com/b/ie/archive/2010/11/01/xhtml-in-ie9.aspx might be useful but obviously I cannot help as I don't have IE9.

    Once a fatal error (well-formedness violation will suffice) is detected, the processor MUST NOT continue normal processing (i.e., it MUST NOT continue to pass character data and information about the document's logical structure to the application in the normal way). Halt on error in essence and stop rendering.

  13. #38
    SitePoint Wizard Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,276
    Mentioned
    50 Post(s)
    Tagged
    2 Thread(s)
    The XHTML 1.0 specs do not state the user agent has to spit out an error or break on an error.
    I hope you're not using Appendix C as some reason for that quote.

    I personally prefer an animated gif of the nyan cat upon fatal error, but that's me.

  14. #39
    ¬.¬ shoooo... silver trophy logic_earth's Avatar
    Join Date
    Oct 2005
    Location
    CA
    Posts
    9,013
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Stomme poes View Post
    I hope you're not using Appendix C as some reason for that quote.
    No I didn't look at Appendix C, the spec (XHTML 1.0) does not dictate that an agent has to display or break on error.
    Either way, IE 9 conforms to XHTML 5 not previous versions of XHTML.
    Logic without the fatal effects.
    All code snippets are licensed under WTFPL.


  15. #40
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    logic_earth
    Good point, I've corrected the text.

    xhtmlcoder
    I've updated it:
    XHTML Test Page will use application/xhtml+xml
    XHTML Test Page will use application/xml
    XHTML Test Page will use text/html
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  16. #41
    SitePoint Wizard Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,276
    Mentioned
    50 Post(s)
    Tagged
    2 Thread(s)
    the spec (XHTML 1.0) does not dictate that an agent has to display or break on error.
    Well now I'm completely confused.
    XHTML1.0 spec says
    A conforming user agent must meet all of the following criteria:

    1. In order to be consistent with the XML 1.0 Recommendation [XML], the user agent must parse and evaluate an XHTML document for well-formedness...
    A user agent who is conforming is one who parses XHTML under XML rules. Anyone who doesn't do this is then not-conforming. So IE isn't conforming.
    So it says a well-formedness error is a fatal error.
    So I look at XML rules regarding fatal errors and it says
    Definition: An error which a conforming XML processor MUST detect and report to the application. After encountering a fatal error, the processor MAY continue processing the data to search for further errors and MAY report such errors to the application. In order to support correction of errors, the processor MAY make unprocessed data from the document (with intermingled character data and markup) available to the application. Once a fatal error is detected, however, the processor MUST NOT continue normal processing (i.e., it MUST NOT continue to pass character data and information about the document's logical structure to the application in the normal way).
    Are you saying that because XHTML1.0 says what a conforming UA is, that it doesn't say anything about UAs breaking on error because they might not be conforming? That IE doesn't have to stop when it hits an error because it's not conforming in the first place?

    Because if it is conforming, then it's parsing with an XML parser; and if it's parsing with an XML parser, then it's stopping when it hits a fatal error (you would call this "breaking on error" correct?).

    This makes absolutely no sense to me.

    Either way, IE 9 conforms to XHTML 5 not previous versions of XHTML.
    What's the difference regarding parsing following XML rules? How can you be a conforming UA to "XHTML5" and not conforming to "previous versions of XHTML" if both say you're conforming if you parse with an XML parser and follow XML parsing rules??

  17. #42
    Robert Wellock silver trophybronze trophy xhtmlcoder's Avatar
    Join Date
    Apr 2002
    Location
    A Maze of Twisty Little Passages
    Posts
    6,316
    Mentioned
    60 Post(s)
    Tagged
    0 Thread(s)
    It's saying if you use a XML Processor that follows the [XML 1.0] rules then it follows the the well-formed constraint of XML and must process the data a such (if served with correct MIME, etc).

    Thus IE9 should obey well-formedness; so it doesn't matter if [IE9] uses Fred [X] or the normative XHTML because both versions follow the XML 1.0 Recommendations for parsing well-formed markup and that will suffice for our simple FATAL ERROR - well-formedness violation test suite.

  18. #43
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    I tried changing the DOCTYPE to XHTML5, which does work:
    XHTML Test Page parses as text/html in Internet Explorer 9
    XHTML Test Page parses as application/xhtml+xml in Internet Explorer 9

    This is, to put it mildly, absolute rubbish.
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  19. #44
    Non-Member bronze trophy
    Join Date
    Nov 2009
    Location
    Keene, NH
    Posts
    3,760
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by C. Ankerstjerne View Post
    This is, to put it mildly, absolute rubbish.
    Try opening them in Opera

    PARENT is not a valid XHTML tag unless you're in 1.1 -- XHTML 5 is based on 1.0, kinda... which means only HTML 4.01/HTML5 tags are supposed to be present.

  20. #45
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    Fixed

    It's just never enough for you, is it?
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  21. #46
    Resident curmudgeon bronze trophy gary.turner's Avatar
    Join Date
    Jan 2009
    Location
    Dallas
    Posts
    990
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Christian,

    Using your first test case, above, the following was the end of all rendering in IE9. Have I misunderstood your conclusion? This appears to indicate IE9 is xhtml+xml conforming.

    If your browser displays any contents below this paragraph, or cannot display this page at all, it means your browser is not compatible with XHTML.
    And, the svg smiley face does render.

    FF, of course, shows only an error message.

    cheers,

    gary
    Anyone can build a usable website. It takes a graphic
    designer to make it slow, confusing, and painful to use.

    Simple minded html & css demos and tutorials

  22. #47
    SitePoint Wizard bronze trophy C. Ankerstjerne's Avatar
    Join Date
    Jan 2004
    Location
    The Kingdom of Denmark
    Posts
    2,702
    Mentioned
    7 Post(s)
    Tagged
    0 Thread(s)
    I can see that removing the erroneous parent element, it does work. Strange, as unknown elements should still be ignored. Anyway, this brings us to:


    Since desc works properly as an alternate text, this will make a valid case for beginning to use XHTML when Internet Explorer 9 becomes a little more popular, assuming vector graphics are needed.
    Christian Ankerstjerne
    <p<strong<abbr/HTML/ 4 teh win</>
    <>In Soviet Russia, website codes you!

  23. #48
    ¬.¬ shoooo... silver trophy logic_earth's Avatar
    Join Date
    Oct 2005
    Location
    CA
    Posts
    9,013
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Stomme poes View Post
    What's the difference regarding parsing following XML rules? How can you be a conforming UA to "XHTML5" and not conforming to "previous versions of XHTML" if both say you're conforming if you parse with an XML parser and follow XML parsing rules??
    (X)HTML 5 have a set defined error-handling method. That is what makes it different. There are no fatal errors in (X)HTML5. Those are the specs IE 9 follows.

    Also, IE does stop the parser, it doesn't move past the point of the error. But the specs do not say IE has to show a message or stop rendering of what it has.
    Logic without the fatal effects.
    All code snippets are licensed under WTFPL.


  24. #49
    Non-Member bronze trophy
    Join Date
    Nov 2009
    Location
    Keene, NH
    Posts
    3,760
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by C. Ankerstjerne View Post
    I can see that removing the erroneous parent element, it does work. Strange, as unknown elements should still be ignored.
    STILL bombing in Opera, and it's not strange. Opera processes XHTML as XML the moment it sees the "prologue", so invalid tags make it bomb -- as per the rules for XML.

    Which is why it's still bombing, you can't say "SVG" either. SVG has to be included via OBJECT or some other means to be used in an HTML document -- regardless of doctype.

    Is there some browser where it's actually rendering that SVG? Because there shouldn't be. Or should I say, there shouldn't be because the change to the HTML 5 Draft that allows for it is too new for anyone to have implemented it... excepting perhaps FF which is who originated the proposed change.

    See "the problem with deploying or even testing DRAFT".

    -- edit -- wait, even with the 5 spec on the table, "D" is an invalid/nonsexistant attribute for SVG. In fact, NONE of the attributes you are trying to use exist under 5... or SVG 1.1 for that matter.
    http://www.w3.org/TR/SVG/struct.html#SVGElement

  25. #50
    SitePoint Wizard Stomme poes's Avatar
    Join Date
    Aug 2007
    Location
    Netherlands
    Posts
    10,276
    Mentioned
    50 Post(s)
    Tagged
    2 Thread(s)
    As I understand it, they're currently going for HTML5's no-need-for-SVG-namespace setup only dealing with a subset of SVG: SVGTiny. So I thought all we're expecting just a subset of SVG to work cross-browser in this manner.

    Which is why it's still bombing, you can't say "SVG" either. SVG has to be included via OBJECT or some other means to be used in an HTML document -- regardless of doctype.
    They're going for
    <svg>
    blah blah blah, no namespace... (also with MathML)
    </svg>
    as a Plain Old Tag... the browser/UA is supposed to "know" that it belongs to the SVG namespace simply because that's the name of the tag. I stumbled into a guy who is the one to follow if you want to keep track of who's doing what with SVG... Erik Dahlström.

    Quote Originally Posted by logic_earth
    There are no fatal errors in (X)HTML5. Those are the specs IE 9 follows.
    Then why is there an X in the name if it doesn't use an XML parser but a modified HTML (HTML5) parser? If the document is sent as application/xhtml+xml it's supposed to be parsed like XML, whether someone is calling it HTML5 or Fred or anything else. So I am still quite confused there: XML parsing rules haven't changed, and XML parsing has fatal errors. What am I missing?

    Also, IE does stop the parser, it doesn't move past the point of the error.
    Good.
    But the specs do not say IE has to show a message
    Correct, they don't
    or stop rendering of what it has.
    You mean not show what it has already parsed without error.
    However your original text was "don't have to ... break on error". This was what confused me. So if you are only saying IE doesn't have to show an error and may show everything it parsed up to the error, then I think I'm clear on that part, thanks.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •