g Text Version
Beauty & Self
Books & Music
Food & Wine
Health & Fitness
Hobbies & Crafts
Home & Garden
News & Politics
Religion & Spirituality
Travel & Culture
TV & Movies

Bored? Games!
Take a Quiz
Rate My Photo

Home Improvement
Women's Fashion
Small Office/Home Office
Holiday/Seasonal Cooking
Crafts for Kids

All times in EST

Full Schedule
g HTML Site

BellaOnline's HTML Editor


XML Basics

Guest Author - Elizabeth Connick

If you've spent some time hanging around web developer forums, you've probably seen the word 'XML' dropped more than once. Out of curiosity, you browse over to the Wikipedia entry for 'XML' and read:

"The Extensible Markup Language (XML) is a general-purpose specification for creating custom markup languages.[1] It is classified as an extensible language because it allows its users to define their own elements. Its primary purpose is to facilitate the sharing of structured data across different information systems, particularly via the Internet,[2] and it is used both to encode documents and to serialize data. In the latter context, it is comparable with other text-based serialization languages such as JSON and YAML..."

By now your eyes are probably glazing over and you’re wishing you’d never even HEARD of XML.

Well, don't panic, because it’s really not as complicated as you think!

XML is, quite simply, a way to store information. The beauty of XML is that it's completely customizable by YOU, the web developer. There's no fussy code to learn or debug, since you can use whatever names you like for the fields. It's actually the easiest programming language to learn because you define most of the code yourself.

OK, let's look at an example. Suppose you wanted to create a catalog of your favorite books. Using XML, your entries would look something like this:

<author>Fred Flintstone</author>
<title>Rock Music</title>
<comments>My favorite book!</comments>

As with HTML, the text between the < > symbols is called a 'tag.' The difference in XML is that you, the web developer, can define your own tags and call them whatever you like. There are a few syntax rules to learn before you start building your own tags:

  • Every opening tag must have a matching closing tag. In other words, if you have the tag <book> in your XML document you must have the closing tag </book> somewhere further down.

  • Unlike HTML, tags in XML are case-sensitive. That means
  • A few characters have pre-defined meanings and can't be used within a tag. They are: less-than symbol (<), greater-than symbol (>), ampersand (&), apostrophe (') and quotation mark (").

Perhaps the biggest advantage to using XML is that its documents are stored on your computer in plain text format. As a result, any computer, browser or server can understand these files regardless of type, so you can easily share data with your visitors. XML files can be used with almost any computer application. It's also easy to call XML files from an HTML page, meaning that you don’t need to worry about redoing HTML every time you add more data – the only thing you need to adjust is the XML document.

Stay tuned for our next article, in which we’ll break down the elements of an XML file and help you build your first XML document.
This site needs an editor - click to learn more!

Add XML+Basics to Twitter Add XML+Basics to Facebook Add XML+Basics to MySpace Add XML+Basics to Del.icio.us Digg XML+Basics Add XML+Basics to Yahoo My Web Add XML+Basics to Google Bookmarks Add XML+Basics to Stumbleupon Add XML+Basics to Reddit

RSS | Related Articles | Editor's Picks Articles | Top Ten Articles | Previous Features | Site Map

For FREE email updates, subscribe to the HTML Newsletter

Past Issues

Printer Friendly
tell friend
Tell a Friend
Email Editor

Content copyright © 2015 by Elizabeth Connick. All rights reserved.
This content was written by Elizabeth Connick. If you wish to use this content in any manner, you need written permission. Contact BellaOnline Administration for details.


g features
What's Coming in HTML 5

What is FTP?

HTML Fundamentals - Tables

Archives | Site Map


Past Issues

Less than Monthly

BellaOnline on Facebook

| About BellaOnline | Privacy Policy | Advertising | Become an Editor |
Website copyright © 2015 Minerva WebWorks LLC. All rights reserved.

BellaOnline Editor