SitePoint Sponsor

User Tag List

Results 1 to 13 of 13

Thread: What is XHTML??

  1. #1
    VICTORY IS MINE! luchazard's Avatar
    Join Date
    May 2001
    Location
    USA
    Posts
    229
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    What is XHTML??

    I hear all about XHTML... but I can't understand the meat of it:

    Does it make webdesign better?

    Do all browsers support it?

    Do all GOOD, BY THE BOOK coders do pages in XHTML now?

    Thanks!

  2. #2
    SitePoint Guru Marc's Avatar
    Join Date
    Nov 2000
    Location
    New York
    Posts
    765
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    xhtml is the W3C's attempt at making coding websites more standar. It is just like html, but a little bit more strict. It really says you have to have all the closing tags, and everything has to be lowercase, and you gotta use quotes, and yatta yatta yatta, all in the name of standards. It's good, yeah, but making the switch will be hard, because sometimes coding too strictly for standards leaves some browsers out... and that isnt good.
    Marc Gugliuzza
    marc.gugliuzza.com



  3. #3
    (****** or Deleted)
    Join Date
    May 2002
    Location
    Melbourne, Australia
    Posts
    299
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Coding in XHTML over HTML is not that much of a change IMHO, I have found the transition extremely smooth, and if you are wanting to still use some HTML properties, you can use XHTML Transitional which is exactly what it is meant for, for people going from plain old HTML to XHTML.

    Check w3schools.com XHTML section, it alone should bring you up to speed in a short time

  4. #4
    SitePoint Wizard iTec's Avatar
    Join Date
    May 2001
    Location
    Sydney, Australia
    Posts
    2,243
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    To quote Ian Glass in another thread

    Anyway, XHTML is pretty simple to learn, and I suggest that be your starting point. In fact, why not learn it right now?
    • Quote all your attributes ( <a href="http://a.com" title="A.com"> );
    • Close all your tags ( <p> </p> and <img ... /> );
    • Nest tags logically and properly ( <p><em>text</em></p> );
    • Learn about which tags and attributes were dropped in XHTML (particularly 1.0 Strict).
    It's really simple...really. ;-)
    An excelent beginners guide to XHTML is the NYPL Style Guide which basically cuts down and rewords the W3c notes

  5. #5
    SitePoint Wizard silver trophy TheOriginalH's Avatar
    Join Date
    Aug 2000
    Location
    Thailand
    Posts
    4,811
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: What is XHTML??

    Originally posted by luchazard
    I hear all about XHTML... but I can't understand the meat of it:

    Does it make webdesign better?
    Absolutely no question, yes.

    Originally posted by luchazard

    Do all browsers support it?
    If it's coded correctly, then yes. However, not all things will look the same in all browsers. All browsers can access the data, which is what's important.

    Originally posted by luchazard

    Do all GOOD, BY THE BOOK coders do pages in XHTML now?

    Thanks!
    Yes, those coders do...
    ~The Artist Latterly Known as Crazy Hamster~
    922ee590a26bd62eb9b33cf2877a00df
    Currently delving into Django, GIT & CentOS

  6. #6
    Prolific Blogger silver trophy Technosailor's Avatar
    Join Date
    Jun 2001
    Location
    Before These Crowded Streets
    Posts
    9,446
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I might add the XHTML has been the standard for almost 3 years now. People that are still using HTML need to modernize. You're not doing yourself or your clients any favor by not, especially when HTML no longer gets parsed correctly by browsers cause it's so old.

    I'm sorry, but people who use NS4, people who code in HTML are beginning to wear on me a bit. All of these things are OLD news and shouldn't even be an issue anymore.

    good luck with your eneavours, though, luchazard.

    Aaron
    Aaron Brazell
    Technosailor



  7. #7
    SitePoint Enthusiast MonsterZero's Avatar
    Join Date
    Jul 2002
    Location
    Worth, IL, USA
    Posts
    96
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    XML (Extensible Markup Language) is a “super” markup language from which programmers can develop other, custom markup languages and specialized applications. XHTML (Extensible Hypertext Markup Language) is one such markup language.

    Programmers already use XML for database and catalog work, and XML also acts as the foundation for standard web protocols including Scalable Vector Graphics (SVG), Synchronized Multimedia Integration Language (SMIL), Wireless Markup Language (WML), and Platform for Privacy Preferences (P3P).

  8. #8
    SitePoint Enthusiast MonsterZero's Avatar
    Join Date
    Jul 2002
    Location
    Worth, IL, USA
    Posts
    96
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    BTW, that's not my quote and I have no clue what XHTML is...but I did stay at a Holiday Inn Express last night.

    [narrator in the background: "it won't make you smarter...but you'll feel smarter"]

  9. #9
    Grumpy Mole Man Skunk's Avatar
    Join Date
    Jan 2001
    Location
    Lawrence, Kansas
    Posts
    2,067
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    XHTML is HTML restructured as an XML application - so to understand what XHTML is you have to understand what XML is. XML is basically a set of rules for defining markup languages, designed to be easily parsable by computers.

    HTML is /not/ easily parsable. It allows attributes with or without quotes, the end tags of many elements are optional and it has a very loose set of rules defining what elements can go where. This means that writing an HTML parser is a very difficult task - you have to account for a whole bunch of strange rule exceptions and syntax possibilities. XML on the other hand is much more strict, and thus is it much easier to write software that can understand it - in fact one of the most important rules of XML is that software should deliberately fail to parse an XML document that is not valid (i.e does not follow the rules of XML).

    XHTML is HTML done the XML way - in other words it's all (or at least many of) the HTML tags you know and love but with the extra strict rules of XML applied. These rules aren't particularly difficult - make sure tags have a matching end tag, nest things properly, quote your attributes. You also need to add a doctype to the top of your document and it is a very good idea to check that your document is valid XHTML once you have finished it using http://validator.w3.org/

    The single biggest advantage of XHTML is that your HTML documents will also be valid XML documents. This means that any piece of software in the world that has the ability to read XML documents will be able to read your XHTML documents (although whether the software will know what to do with the data is another thing altogether). If you ever decide to write some kind of program to processs web pages the usefulness of XHTML will immediately become apparent as you will be able to use XML software tools to process your XHTML pages.

    I hope that's clear

  10. #10
    SitePoint Enthusiast
    Join Date
    Jan 2002
    Location
    Mississippi
    Posts
    76
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    xhtml

    files are still saved *.html or *.htm though, right? you dont' have to save files *.xhtml.
    Derrick
    Creativity is great, but plagiarism is faster!

  11. #11
    ********* Genius Mike's Avatar
    Join Date
    Apr 2001
    Location
    Canada
    Posts
    5,458
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You don't have to, but you can. I believe all of the following are correct: .xhtml .xht .xhtm .htm .html

    Please, correct me if I'm wrong
    Mike
    It's not who I am underneath, but what I do that defines me.

  12. #12
    ********* Genius Mike's Avatar
    Join Date
    Apr 2001
    Location
    Canada
    Posts
    5,458
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    On a similar note, has there been any word on the release of XHTML 2.0? I take it the project is still going strong, correct?
    Mike
    It's not who I am underneath, but what I do that defines me.

  13. #13
    Grumpy Mole Man Skunk's Avatar
    Join Date
    Jan 2001
    Location
    Lawrence, Kansas
    Posts
    2,067
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The first publc draught of XHTML 2.0 was announced a few weeks ago - I blogged it here:

    http://www.bath.ac.uk/~cs1spw/blog/a.../08/06/#xhtml2

    However, it is unlikely it will be worth using for several years (it will take that long for decent browser support to emerge).

    Personally I'm sticking to XHTML 1.0 Strict at the moment and have no plans to change, at least not unless I can see a good reason to.


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
  •