Chapter 19. How Markup Languages Work


Markup languages are the road signs of a web page. They are sets of directions that tell the browser software how to display and manage a web document, much like written music scores are instructions that tell a musician how to play a particular song. These instructions (called tags or markups) are embedded in the source document that creates the web page.

Tags reference graphic images located in separate files, and they instruct the browser to retrieve and display these images within the page. Tags can also tell a browser to connect a user to another file or URL when he clicks an active hyperlink. So each web page has everything it needs to be displayed on any computer with a browser that can interpret the markup language.

Your original text will probably have headings, multiple paragraphs, and some simple formatting. A web browser will not understand all these layout instructions because the original text isn't formatted with HTML, the language of the Web (discussed later in this chapter). Paragraphs, carriage returns, indents, and multiple spaces will be shown instead as a single space if no HTML markup is added.

Markup languages should not be confused with programming languages, such as C+ or Pascal. Programming languages are used to write complex applications, such as word processors or spreadsheets. Markup languages, in contrast, are much simpler and describe the way information should be displayedfor example, by defining when text should be boldface. In markup languages, tags are embedded within documents to describe how the documents should be formatted and displayed.

Hypertext Markup Language (HTML) is the markup language of the Web. It defines the format of a web document and enables hypertext links to be embedded in the document. You can use any text editor or word processor to add HTML tags to an ASCII text document, although a number of shareware and commercially available HTML editors can assist web page authors as well.

The Web evolves daily, and HTML also expands and changes along with it. A group of technologies that together are termed Dynamic HTML (DHTML) have grown out of HTML, and allow HTML to be more than a static language. They enable HTML to perform animations and become more interactive and flexible.

The Extended Markup Language (XML) promises to bring even more significant changes to the Web. It's dramatically different from other markup languages because it separates the content of a page from its presentation. Rather than doing things such as giving instructions on text size, it tags different types of content and then has other technologies such as templates and style sheets determine how that content should look.

XML is at the core of a new technology called Web Services, which allow programs and services to be delivered across the Internet using a web browser. (To see how Web Services work, turn to Chapter 25, "How .NET and Web Services Work.")

The newest XML-related technology is AJAX, which allows websites to function more like desktop programs than websites. It allows for a great deal of interactivity, unlike most web pages, which are slow and static.



How the Internet Works
How the Internet Works (8th Edition)
ISBN: 0789736268
EAN: 2147483647
Year: 2004
Pages: 223

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net