Home >> FAQs/Tutorials >> XHTML Tutorials and Tips >> Index
XHTML Tutorial - "base" Tag/Element
(Continued from previous topic...)
What Is the "base" Tag/Element?
The "base" element is an optional sub-element of the "head" element.
The "base" element specifies a base URL for all the hyper links in XHTML
document. It has one required attribute called "href" to allow you to
specify the base URL.
Here is an example:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<base href="http://dev.fyicenter.com/faq/" />
<title>My First XHTML Document</title>
</head>
<body>
<p><img src="images/fyi.gif" alt="FYI" /></p>
</body>
</html>
If you view this document in a browser, the image will be fetched from
http://dev.fyicenter.com/faq/images/fyi.gif.
(Continued on next topic...)
- What is the Top Level Structure of an XHTML Document?
- How Many Document Types Defined in XHTML 1.0?
- What Is the "html" Tag/Element?
- What is the Second Level Structure of an XHTML Document?
- What Is the "head" Tag/Element?
- What Is the "body" Tag/Element?
- How To Write a "head" Element Properly?
- What Is the "title" Tag/Element?
- What is a Smallest Valid XHTML Dodument?
- What Is Wrong with This "head" Element?
- What Happens If the "title" Element is Missing?
- What Happens If a "meta" Element Is Not Closed?
- What Is a "meta" Tag/Element?
- What Is the Description "meta" Tag/Element?
- What Is the Keywords "meta" Tag/Element?
- What Is the Robots "meta" Tag/Element?
- What Is a http-equiv "meta" Tag/Element?
- What Is the Author "meta" Tag/Element?
- What Is the "base" Tag/Element?
- What Is a "script" Tag/Element?
- What Is a "link" Tag/Element?
- What Is a "style" Tag/Element?
|