|Submitted By -
| What is XHtml?
|As the Worldwide Web Consortium (W3C) describes it, XHTML (Extensible Hypertext Markup Language) is "a reformulation of HTML 4 as an application of the Extensible Markup Language (XML)." For readers unacquainted with either term, HTML is the set of codes (that's the "markup language") that a writer puts into a document to make it displayable on the World Wide Web. HTML 4 is the current version of it. XML is a structured set of rules for how one might define any kind of data to be shared on the Web. It's called an "extensible" markup language because anyone can invent a particular set of markup for a particular purpose and as long as everyone uses it (the writer and an application program at-the receiver's end), it can be adapted and used for many purposes - including, as it
happens, describing the appearance of a Web page. That being the case, it seemed desirable to reframe HTML in terms of XML. The result is XHTML, a particular application of XML for "expressing" Web pages. .
XHTML is, in fact, the follow-on version of HTML 4. You could think of it as HTML 5, except that it is called XHTML 1.0. In XHTML, all HTML 4 markup tags and attributes (the language of HTML) will continue to be supported. Unlike HTML, however, XHTML can be extended by anyone that uses it. New tags and attributes can be defined and added to those that already exist, making possible new ways to embed content and programming in a Web page. In appearance, an XHTML file looks like a somewhat more elaborate HTML file.
To quote the W3C again, the advantages are "extensibility and portability."
Extensibility means that as new ideas for Web communication and presentation emerge, they can be implemented without having to wait for the next major version of HTML and browser support. New tags or attributes can be defined to express the new possibilities and, assuming some program at the receiving end can. Understand and act (them, new things may happen on your Web page that never happened before. Specific sets of extensions for XHTML are planned for. Mathematical expressions, vector graphics, and multimedia applications.
If extensibility is likely to lead to more complicated pages and larger programs, the portability advantage means that Web pages can now be made simpler than they were before so that small devices can handle them. This is important for mobile. Devices and possibly household devices that contain microprocessors with embedded programming and smaller memories. XHTML defines several levels of possible markup complexity and each document states its level of complexity at the beginning. Programs in micro devices might expect XHTML-coded files that state the simplest level of complexity so that they could be handled by a small program and memory.
Differences and Distinctive Features
You can find out more by reading the specification and tutorials, but here are some distinctive features of XHTML and differences between HTML 4:
XHTML requires strict adherence to coding rules. Notably, it requires that you use closing as well as opening tags (this is known as well-formed syntax) and that all tags be in lower case.
HTML was much less rigorous about notation and browsers tended to be even forgiving. This means that XHTML files will tend to be "busier" than HIML. However, they won't necessarily be harder to read because rigor may force more order in coding. In addition, the major editing and file creation tools will probably layout pages for easier readability.
XHTML would seem to encourage a more structured and conceptual way of thinking about content and, combined with style sheets, a more creative way of displaying it.
XHTML will make it easier for people to dream up and add new tags (and develop browsers OF other applications that support them).
The first XHTML specification is currently in the W3C Working Draft stage.