Friday, 31 March 2012
XML
What is XML ?
XML is a markup language for documents containing structured information. XML is a way of adding intelligence to your documents. It lets you identify each element using meaningful tags and it lets you add information ("metatdata") about each element. XML is a syntax for marking up data and it works with many other technologies to display and process information. It looks and feels very much like HTML.
A markup language is a mechanism to identify structures in a document. The XML specification defines a standard way to add markup to documents.
The design goals of XML, taken from the XML Specification are:
· XML shall be
straightforwardly usable over the Internet.
· XML shall support a
wide variety of applications.
· XML shall be
compatible with SGML.
· It shall be easy to
write programs which process XML documents.
· The number of
optional features in XML is to be kept to the absolute minimum, ideally zero.
· XML documents should
be human-legible and reasonably clear.
· The XML design
should be prepared quickly.
· The design of XML
shall be formal and concise.
· XML documents shall
be easy to create.
· Terseness in XML markup is of minimal importance.
· Terseness in XML markup is of minimal importance.
XML Vs HTML :
1.HTML is a markup language for a specific
purpose (display in browsers)
purpose (display in browsers)
2.XML is a framework for defining markup
languages.
3.HTML can be formalized as an XML language
(XHTML)
(XHTML)
4.XML defines logical structure only.
5.HTML: same intention, but has evolved into
a presentation language
a presentation language
XHTML
What is XHTML ?
XHTML stands for EXtensible HyperText Markup Language and is the next step in the evolution of the Internet. XHTML was developed by the W3C to help web developers make the transition from HTML to XML.
In general you can get away with more short-cuts, and possibly even less work by using HTML rather then XHTML - nevertheless, we still recommend making an effort to use XHTML code in your Website because of all the long term benefits!
Why XHTML ?
- XHTML is more strict syntax rules has many benefits.
- It also makes your website more easy to maintain, edit, convert and format in the long run.XHTML adopts official XML standard syntax, and is a newer technology with many benefits.
- Since XHTML is an official standard of the World Wide Web Consortium (W3C).
5 advantages of XHTML over HTML :
1. Sustainability.
As web applications get increasingly sophisticated and move towards XML the use of XHTML will be more widespread.
2. Wide range of applications.
Due to the large number of applications that XHTML can support it can be used to create more complex websites. For instance MathML(Math Markup language) SVG(Scalable Vector Graphics)or users own mark up variants can all be supported in XHTML.However browsers that support such applications are few.
3. Compatibility.
The XHTML documents are written in compliance with the rules of XML,XML processing programmes can therefore convert an XHTML document into PDF,RSS or RFT.This enables you to work with a wide range of file formats.
4. Efficient processing applications.
Though the number of browsers that can support XHTML are few and far between the few that are available are quicker thanks to shorter error processing routines. At the moment a greater amount of processing time is spent by browsers on liberal error processing of documents containing malformed HTML markup. This will there reduce the loading time of your pages and downloads will be quicker.
5. Closing tags
Unlike HTML, all XHTML have closing tags. This is great for beginners and even helps seasoned web design professionals keep up with their work.XHTML makes your source clean and readable which can enhance your appeal as a web design professional. The website appears more professional and this is likely to increase the number of customers. In a nutshell XHTML shows professionalism as opposed to html which is more suited to personal websites.
Example Program for XHTML :
Output:
Differences Between HTML & XHTML :
The difference between HTML and XHTML is in their respective syntax - the main differences are discussed in this section.
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> This is Basic Structure Of XHTML. </html>
Output:
This is Basic Structure Of XHTML.
Differences Between HTML & XHTML :
The difference between HTML and XHTML is in their respective syntax - the main differences are discussed in this section.
- XHTML requires that all Webpages contain the <html>, <head>, and <body> elements, as well as the DOCTYPE declaration, where as in HTML they are not required.
- XHTML insists on having closing tags for every element, even empty ones, where as HTML often lets you omit them.
- HTML requires that all attributes be enclosed by quotation marks, where as HTML lets you omit quotation marks, but only around attribute values which consist of only letters, numbers and these characters: - (dash), . (period), _ (underscore) and : (colon).
- XHTML is case sensitive, where as HTML is not case sensitive. Furthermore XHTML requires that all enumerated attribute values be lower case.
HTML
What is HTML ?
HTML is a computer language devised to allow website creation. These Website can be viewed by anyone else connect the Internet. It is relatively easy to learn, with the basics being accessible to most people in one sitting; and quite powerful in what it allows you to create.
The Definition of HTML is Hyper Text Markup Language.
<html>
<body>
<h1>This is My First Blog</h1>
<p>My first paragraph.</p>
</body>
</html>
HTML Tags :
HTML is a computer language devised to allow website creation. These Website can be viewed by anyone else connect the Internet. It is relatively easy to learn, with the basics being accessible to most people in one sitting; and quite powerful in what it allows you to create.
The Definition of HTML is Hyper Text Markup Language.
- Hyper Text : It is the method by which you move around on the web-by clicking on special text called Hyperlinks which bring you to the next page.
- Markup : It is what HTML tags do to the text inside them. They mark it as a certain type of text.
- HTML is written in the form of HTML elements consisting of tags enclosed with in Angular-Brackets (like <html>).
- HTML tags most commonly come in the pair like <h>and</h>. First tag is called Starting tag & second tag is called ending tag.
<html>
<body>
<h1>This is My First Blog</h1>
<p>My first paragraph.</p>
</body>
</html>
HTML Tags :
To use any of the following HTML tags, simply select
the HTML code you'd like and copy and paste it into your web page.
| Tag | Name | Browser View |
|---|---|---|
| !-- | comment | Nothing will show (Tip) |
| A- | Anchor | Visit Our Site |
| B | Bold | Example |
| BIG | Big(text) | Example |
| BODY | body of HTML document | The content of your HTML page |
| BR | line break | The contents of your page The contents of your page |
| CENTER | center | |
| DD | definition descriptiont |
|
| DL | definition list |
|
| DT | definition list |
|
| EM | emphasis | This is an Example of using the emphasis tag |
| EMBED | embed object | |
| FONT | font | Example |
| FONT | font | Example |
| FONT | font | Example |
| FORM | form | |
| H1 | heading 1 | Heading 1 Example |
| H2 | heading 2 | Heading 2 Example |
| H3 | heading 3 | Heading 3 Example |
| H4 | heading 4 | Heading 4 Example |
| H5 | heading 5 | Heading 5 Example |
| H6 | heading 6 | Heading 6 Example |
| HEAD | heading of HTML document | Nothing will show (Tip) |
| HR | horizontal rule | |
| HR | horizontal rule | |
| HR | horizontal rule | |
| HR(Internet Explorer) | horizontal rule | |
| HR(Int |
No comments:
Post a Comment