“webinar”/ paypertrail
  1. Null

Welcome to Our Community
Wanting to join the rest of our members? Feel free to sign up today.

Null

 

XHTML vs HTML ?

Discussion in 'Programming and Scripts' started by Davidwatson, Jun 22, 2016.

  1. Davidwatson

    Davidwatson Affiliate affiliate

    15
    2
    0
    Hey guys,

    Simple question for you tag geniuses, what's the real difference between XHTML and HTML (apart from the X of course). I need to get this right so anyone with links or info explaining this would be awesome!
     
  2. Golden Goose
  3. Brianvoges

    Brianvoges Affiliate affiliate

    21
    10
    3
    XML syntax rules are far more rigorous than HTML. As a result, XHTML makes authors work more precisely, having to address issues such as:

    • all elements and attribute names must appear in lower case
    • all attribute values must be quoted
    • non-Empty Elements require a closing tag
    • empty elements are terminated using a space and a trailing slash
    • no attribute minimization is allowed
    • in strict XHTML, all inline elements must be contained in a block element
     
  4. designpluz

    designpluz Affiliate affiliate

    180
    19
    18
    Both are important for search engine look up and human look up of your website
     
  5. Davidwatson

    Davidwatson Affiliate affiliate

    15
    2
    0
    Thanks for describing it,
     
  6. ushaa4n

    ushaa4n Affiliate affiliate

    72
    18
    0
    thanks for sharing this..
     
  7. johnbrent

    johnbrent Affiliate affiliate

    207
    39
    28
    - XHTML is more choosy than HTML—there are some elements that absolutely must appear in the XHTML markup, but which may be omitted if you’re using HTML 4 and earlier versions. These elements include the html, head, and body elements (although why you’d want to omit any of them is a mystery to me). In addition, every element you use in XHTML must have both an opening and closing tag (for example, you’d write <p>This is a paragraph</p> in XHTML, but <p>This is all you need in HTML, as no end tag is required).

    - XHTML allows us to indicate any element as being empty—for example, an empty paragraph can be expressed as <p/>—but this isn’t valid when the page is served as text/html. To that end, you should restrict your use of this syntax to elements that are defined to be empty in the HTML specifications.

    - In XHTML, all tags must be written in lowercase. In HTML, you can use capital letters for elements, lowercase letters for attributes, etc.

    - In XHTML, all attributes must be expressed in attribute-name and attribute-value parings with quote marks surrounding the attribute value part, like so: class="fuzzy".
     
  8. Ajax Hill

    Ajax Hill Affiliate affiliate

    17
    2
    0
    I'll recommend XHTML, because it is easy to learn, because it is blinded in the limitations of rules and practicing XHTML will make you also very expert while you'll use xml.
     
  9. VirtualGlobalPhone

    VirtualGlobalPhone Moderator moderator Service Manager affiliate

    2,119
    914
    113
    @intuitionsoftech

    Consider this as Waring do not put copyrighted material as your answer. Please read the rules of the forum. You have simply copied from XHTML - Wikipedia, the free encyclopedia and pasted here.

    If found again we may have to audit all your post and may take strict action.
     
  10. Jack Ramon

    Jack Ramon Affiliate affiliate

    71
    4
    8
    HTML, is an application of SGML (Standard Generalized Markup Language) and allows an author to omit certain tags and use attribute minimization.

    XHTML, is an application of XML (Extensible Markup Language) that doesn’t permit the omission of any tags or the use of attribute minimization. However, it provides a shorthand notation for empty elements—for example, we could use <br/> instead of <br></br>—which HTML does not.
     
  11. James Orji

    James Orji Affiliate affiliate

    12
    8
    3
    XHTMl is an advanced version of HTML and it will do you a lot of good to use it as opposed to plain HTML.
     
  12. drappiro

    drappiro Affiliate affiliate

    10
    3
    3
  13. martinsmith

    martinsmith Affiliate affiliate

    98
    17
    8
    Thanks for sharing nice info...
     
  14. FleHost

    FleHost Affiliate affiliate

    10
    1
    3
    most used is html code
     
  15. Shreya Surana

    Shreya Surana Affiliate affiliate

    11
    1
    3
    HTML and XHTML are both languages in which web pages are written. HTML is SGML-based while XHTML is XML-based. They are like two sides of the same coin. XHTML was derived from HTML to conform to XML standards. Hence XHTML is strict when compared to HTML and does not allow user to get away with lapses in coding and structure.

    The reason for XHTML to be developed was convoluted browser specific tags. Pages coded in HTML appeared different in different browsers.
     
  16. Certified
    kvchosting

    kvchosting New Member Certified Vendor Service Manager affiliate

    14
    6
    3
    HTML is an abbreviation for HyperText Markup Language. HTML was designed to display data with focus on how data looks. XML was designed to be a software and hardware independent tool used to transport and store data, with focus on what data is. XML provides a framework for defining markup languages
     
  17. Graybeard

    Graybeard Well-Known Member affiliate

    1,828
    894
    113
banners