XML

Introduction

XML, or eXtensible Markup Language, is a meta-language that allows customised mark-up languages to be defined. An XML document has a hierarchical structure, with all the elements of the XML document being represented as members of a pyramidal structure, such that each element is the child element of a parent element, with the exception of the root element. XML looks like HTML, but customised element names can be created.

Contents

Use

Example

An XML document is a text file.

<?xml version="1.0"?> <people> <person> <name>John Smith</name> <telephone>0123-456-789</telephone> </person> <person> <name>Jane Jones</name> <telephone>0987-654-321</telephone> </person> <person> <name>William Edwards</name> <telephone>0121-232-343</telephone> </person> </people>

Example

The following document shows an XML document that could describe the menu system on a mobile phone.

src/xml/mobilePhoneMenus.xml