Download HTML Lesson 1

yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts

URL redirection wikipedia, lookup

Timmerman 2013
These are the tags required in every Web page. (Note: some are not technically required by
the HTML specification, but some browsers will not render correctly without them, so it is
always better to leave them in than out - the space you save is not worth the problems you
might cause.)
The DOCTYPE element is not really an XHTML element, but rather an identifier for the
page. In order to create a valid XHTML document, you need to include the DOCTYPE. The
DOCTYPE references a DTD, and there are three DTDs you can use:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
This is the strict DTD, I wouldn't recommend using this DOCTYPE unless you plan to
be very careful with your XHTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
This is the transitional DTD; it is the best one to use for most Web sites
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
This is the frameset DTD; if you're going to put up a framed page, you should use
this DTD
The first tag that any Web page must have is the <html> tag. It tells the browser that the
following text will be marked up in HTML format, and not some other format such as
straight text, SGML, or XML. The closing tag </html> is required and is the last tag in your
The <head> tag is used to define information for the browser that may or may not be
displayed to the user. Tags that belong in the <head> section are <title>, <meta>, <script>,
and <style>. The closing tag </head> is required.
The <title> tag belongs in the <head> section of your document. It is the title of your Web
page, and is usually displayed by the browser at the top of the browser pane. The closing
tag </title> is required.
Timmerman 2013
The <body> tag is where all your HTML information belongs. It defines the primary portion
of your Web page. With attributes of the <body> tag, you can define the background color
of your Web pages, the text color, the link color, and the active and visited link colors. The
closing tag </body> is required.
A sample Web page would look like this:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
This is the title of the page.
The body text goes here.