CSCI 121 - Lecture 2 - HTML Essentials
Instructor's Class Notes
- History of the World Wide Web
- 25 years old (see CNET article).
- Proposed by Tim Bernards-Lee, CERN Switzerland, in 1990.
- The Internet was made public on August 23rd, 1991.
- First web page of the WWW is still publised at it's same URL http://info.cern.ch/hypertext/WWW/TheProject.html
- Introduction to HTML
- HTML is a markup language for describing web documents (web pages). HTML stands for Hyper Text Markup Language. A markup language is a set of markup tags. HTML documents are described by HTML tags. Each HTML tag describes different document content.*
- Excellent resource: http://www.w3schools.com/
- HTML tag - the first tag of an HTML document
- HEAD tag - typically the second tag of an HTML document, can hold any of the following tags
- TITLE - required in an HTML document
- defines a title in the browser toolbar
- provides a title for the page when it is added to favorites
- displays a title for the page in search-engine results
- STYLE - The style tag is used to define style information for an HTML document.
- Inside the style element you specify how HTML elements should render in a browser.
- Each HTML document can contain multiple style tags.
- More discussion on STYLE and styles when we cover Cascading Style Sheets (CSS).
- BASE - The base tag specifies the base URL/target for all relative URLs in a document.
- LINK - Link to an external style sheet or other external resource file.
- META - The meta tag tag provides metadata about the HTML document. Metadata will not be displayed on the page, but will be machine parsable.
- Meta elements are typically used to specify page description, keywords, author of the document, last modified, and other metadata.
- The metadata can be used by browsers (how to display content or reload page), search engines (keywords), or other web services.
- SCRIPT - The script tag is used to define a client-side script (JavaScript).
- The script element either contains scripting statements, or it points to an external script file through the src attribute.
- Common uses for JavaScript are image manipulation, form validation, and dynamic changes of content.
- NOSCRIPT - The noscript tag defines an alternate content for users that have disabled scripts in their browser or have a browser that doesn't support script.
- The noscript element can be used in both head and body.
- When used inside the head element: noscript must contain only link, style, and meta elements.
- The content inside the noscript element will be displayed if scripts are not supported, or are disabled in the user's browser.
- BODY - The body tag defines the document's body.
- The body element contains all the contents of an HTML document, such as text, hyperlinks, images, tables, lists, etc.
* from w3school.com