Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^7: Wiki-Style syntax for posting

by SFLEX (Chaplain)
on Oct 16, 2008 at 13:39 UTC ( [id://717499]=note: print w/replies, xml ) Need Help??


in reply to Re^6: Wiki-Style syntax for posting
in thread Wiki-Style syntax for posting

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re^8: Wiki-Style syntax for posting
by ikegami (Patriarch) on Oct 16, 2008 at 14:22 UTC

    which is only meant for "backward compatible"

    You've read too much into it. Using empty tags to represent empty elements is part of XML. It's not something that was added to XHTML for backwards compatibility with HTML.

    the proper way to use a XHTML br tag is <br />

    XML and thus XHTML allows it, so <br></br> is also correct, proper. You can make recommendations as to which syntax to use — and I'll agree with you that <br/> is less problematic — but you're out of line in saying one of them is incorrect.

    a XHTML br tag is <br /> which has no "backward compatible" and is true XHTML

    You have it backwards. <br /> is more "backwards compatible" to HTML than <br></br>. <br /> is interpreted as <br> by browsers, but <br></br> is interpreted as <br><br>. If your argument had merit, it would dictate that <br></br> is the proper way.

      Ok, the way I see it is true XHTML is what ever is going to validate under the Strictest Rules of XHTML.
      So then i made up a little markup that can be ran at http://validator.w3.org/
      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w +3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html lang="en-US" xml:lang="en-US" xmlns="http://www.w3.org/1999/xht +ml"> <head> <title>HTML BR TAG</title> </head> <body> <p>This is Good<br /></p> <p>This is wrong<br><br/></p> </body> </html>

      Scroll down till you see "Validate by direct input" paste the markup above in it, select "Use Doctype XHTML 1.0 Strict", you can also check "Show Source" and "Clean up Markup with HTML Tidy" HTML tidy will show the right markup to use.

      Spiel auf Hündinnen.

        Ok, the way I see it is true XHTML is what ever is going to validate under the Strictest Rules of XHTML.

        That's a fair meter.

        Now, if only you had tested what we were talking about.
        <p>This is wrong<br><br/></p>
        should be
        <p>This is wrong<br></br>...or not</p>

        Once you do that, you'll get "This document was successfully checked as XHTML 1.0 Strict!". So, both <br/> and <br></br> are accepted by w3c's XHTML validator.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://717499]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-06-15 20:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.