Creating a simple HTML page

Similar documents
1 Creating a simple HTML page

What You Will Learn Today

11. HTML5 and Future Web Application

Html basics Course Outline

Creating Web Pages Using HTML

HTML Images - The <img> Tag and the Src Attribute

CSC 101: PreLab Reading for Lab #4 More HTML (some of this reading on Tables and Images are based on previous writings of Prof William Turkett)

Dreamweaver Basics Workshop

Web Design 101. What is HTML? HTML Tags. Web Browsers. <!DOCTYPE html> <html> <body> <h1>my First Heading</h1> <p>my first paragraph.

Islamic University of Gaza Faculty of Engineering Department of Computer Engineering ECOM Advanced Internet Technology Lab.

I-5 Internet Applications

CSC 101: Lab #2 HTML and the WWW Manual and Report Lab Date: Tuesday, 2/2/2010 Report Due Date: Friday, 2/5/2010 3:00pm

CSC 121 Computers and Scientific Thinking

HTMLnotesS15.notebook. January 25, 2015

Chapter 4 Notes. Creating Tables in a Website

The default style for an unordered (bulleted) list is the bullet, or dot. You can change the style to either a square or a circle as follows:

Unit 5 Web Publishing Systems Page 1 of 13 Part 4 HTML Part 4

Creating A Web Page. Computer Concepts I and II. Sue Norris

HTML OBJECTIVES WHAT IS HTML? BY FAITH BRENNER AN INTRODUCTION

HTML What is HTML Hyper Text Markup Language is a computer based language used to create WebPages.

recall: a Web page is a text document that contains additional formatting information in the HyperText Markup Language (HTML)

Title: Jan 29 11:03 AM (1 of 23) Note that I have now added color and some alignment to the middle and to the right on this example.

AOS Lab 4 HTML, CSS and Your Webpage

Introduction to Computer Science (I1100) Internet. Chapter 7

Introduction to Computer Science (I1100) Internet. Chapter 7

This booklet is knowledge of. a web page. of a web page find what you. you want to. SiteSell offers. Introduction

WEB APPLICATION. XI, Code- 803

Web Page Creation Part I. CS27101 Introduction to Web Interface Design Prof. Angela Guercio

A Balanced Introduction to Computer Science, 3/E

FIT 100 LAB Activity 3: Constructing HTML Documents

Beginning HTML. A tag is a command written between angle brackets (the less than and greater than symbols). Ex. <html>

Authoring World Wide Web Pages with Dreamweaver

About Netscape Composer

INTRODUCTION TO WEB USING HTML What is HTML?

1. Please, please, please look at the style sheets job aid that I sent to you some time ago in conjunction with this document.

Bridges To Computing

TEST NAME: MMWD 4.01 TEST ID: GRADE:09 - Ninth Grade Twelfth Grade SUBJECT:Computer and Information Sciences TEST CATEGORY: My Classroom

HTML4 TUTORIAL PART 2

HTML for the SAS Programmer

CSC Web Programming. Introduction to HTML

UNIT 3 SECTION 1 Answer the following questions Q.1: What is an editor? editor editor Q.2: What do you understand by a web browser?

AOS 452 Lab 4: HTML, CSS and Your Webpage

The Internet & The World Wide Web

All Creative Designs. Basic HTML for PC Tutorial Part 2 Using MS Notepad Revised Version May My First Web Page

Chapter 4. Introduction to XHTML: Part 1

By Ryan Stevenson. Guidebook #2 HTML

request HTML Document send HTML Document

Working with HTML. must appear at the very beginning of your webpage. starts the first section of your page

CS Multimedia and Communications REMEMBER TO BRING YOUR MEMORY STICK TO EVERY LAB!

Training Sister Hicks

Lesson 1 HTML Basics. The Creative Computer Lab. creativecomputerlab.com

Web Programming Week 2 Semester Byron Fisher 2018

LAB 3 CSE 3, Spring 2018 In this lab you will learn and implement some basic html.

HTML. LBSC 690: Jordan Boyd-Graber. October 1, LBSC 690: Jordan Boyd-Graber () HTML October 1, / 29

16A. Laboratory. First Steps in HTML. Objective. References. Learn some basic HTML concepts. Make a simple web page.

HTML TIPS FOR DESIGNING.

HTML Tags <A></A> <A HREF=" CNN </A> HREF

HTML Tags (Tutorial, Part 2):

Chapter 2. Self-test exercises

CS 103, Fall 2008 Midterm 1 Prof. Nakayama

GIMP WEB 2.0 MENUS. Web 2.0 Menus: Horizontal Navigation Bar with Dynamic Background Image

Creating Web Pages. Getting Started

HTML & CSS for Library Professionals

HTML. Hypertext Markup Language. Code used to create web pages

HTML Exercise 24 Tables

Programmazione Web a.a. 2017/2018 HTML5

16B. Laboratory. Linking & Images in HTML. Objectives. References

HTML & XHTML Tag Quick Reference

How to lay out a web page with CSS

Part 1: HTML Language HyperText Make-up Language

Table-Based Web Pages

Lab 1: Introducing HTML5 and CSS3

Chapter 4 A Hypertext Markup Language Primer

INFS 2150 / 7150 Introduction to Web Development & HTML Programming

c122jan2714.notebook January 27, 2014

Indian Institute of Technology Kharagpur. HTML Part III. Prof. Indranil Sen Gupta Dept. of Computer Science & Engg. I.I.T.

HTML. Mohammed Alhessi M.Sc. Geomatics Engineering. Internet GIS Technologies كلية اآلداب - قسم الجغرافيا نظم المعلومات الجغرافية

The City School. Prep Section. ICTech. 2 nd Term. PAF Chapter. Class 8. Worksheets for Intervention Classes

The City School. Prep Section. ICTech. 2 nd Term. PAF Chapter. Class 7. Worksheets for Intervention Classes

Tables *Note: Nothing in Volcano!*

CSE 3. Marking Up with HTML. Comics Updates Shortcut(s)/Tip(s) of the Day Google Earth/Google Maps ssh Anti-Spyware

Hyper Text Markup Language

How the Internet Works

Lab Introduction to Cascading Style Sheets

ADOBE DREAMWEAVER CS4 BASICS

Hyper Text Markup Language

Lab 4 CSS CISC1600, Spring 2012

Markup Language SGML: Standard Generalized Markup Language. HyperText Markup Language (HTML) extensible Markup Language (XML) TeX LaTeX

A HTML document has two sections 1) HEAD section and 2) BODY section A HTML file is saved with.html or.htm extension

Web Development and HTML. Shan-Hung Wu CS, NTHU

HyperText Markup Language (HTML) is the language of the web. When

Basic HTML. Lecture 14. Robb T. Koether. Hampden-Sydney College. Wed, Feb 20, 2013

BASIC HTML LAB 4. Vocabulary. Discussion and Procedure

Introduction to HTML. SSE 3200 Web-based Services. Michigan Technological University Nilufer Onder

GIMP WEB 2.0 MENUS. Web 2.0 Menus: Horizontal Navigation Bar

LING 408/508: Computational Techniques for Linguists. Lecture 14

Lab: Create JSP Home Page Using NetBeans

Lab 3. CSE 3, Summer 2010 In this lab you will learn and implement some basic html.

It is possible to create webpages without knowing anything about the HTML source behind the page.

5/17/2009. Marking Up with HTML. An HTML Web Page File. Tags for Bold, Italic, and underline. Structuring Documents

Transcription:

cis3.5, fall 2009, lab I.2 / prof sklar. Creating a simple HTML page 1 Overview For this assignment, you will create an HTML file in a text editor. on a PC, this is Notepad (not Wordpad) on a Mac, this is TextEdit (in plain text mode, not rtf) on Linux, this is pico or emacs or vi... Type your name in the files as comments. Comments in HTML are lines that begin with the tag: <!-- and end with -->. <!-- this is prof sklar s html file. --> <html> <body> hello! </html> Save your work!!! BEFORE YOU LEAVE THE LAB, make sure that you save your work (both HTML files and any images files you use) by storing them on a USB flash drive or by emailing them to yourself (ask me if you don t know how to do this). 2 Getting started Open the appropriate text editor for the type of computer you are using. In this file, you will write HTML code to do the things listed below. Start by creating the outline for the page. All HTML pages begin with a <html> tag and end with a <\html> tag. In between these tags, the page is divided into two parts: the head and the body. These tags also have start and end forms: <head> and </head>, and <body> and. Things that go inside the head tags do not appear directly in the content of the page, but are used to control the page in various ways. The content of the page goes between the body tags. The page outline should look like this: <html> <head> </head> <body> </html>

Set the title of the web page by inserting title tags (<title>...</title>) inside the head tags. When you view the HTML page, the title will be displayed inside the browser window s top heading bar, not in the body of the browser s content. <head> <title>prof sklar s sample home page</title> </head> Set the background color of the page to something other than the default (usually white) and the text color of the page to something other than the default (usually black). You can do this using the body tag and the bgcolor parameter, like this: <body bgcolor="yellow" text="blue"> Note that you will be modifying the body tag that you put in above, not adding another one. There should be only one body tag in an HTML document. Display a heading that welcomes the user to your web page. This needs to go in between the body tags. <body bgcolor="yellow" text="blue"> <h1>welcome to Prof Sklar s home page!</h1> Save the file and name it with your last name followed by -home.html. For example, my file is called: sklar-home.html Note that some text editors, particularly on Windows, want to put a.txt extension after the.html extension. Don t do it. Try opening the file with a browser (like Netscape or Safari or IE) and see what your page looks like. In the browser, select File - Open File... and then enter the name of your HTML file (e.g., sklar-home.html). If any of the elements above don t work, go back into the text editor, and edit the file to fix them. Then reload the file in your browser. Keep doing this until everything looks just perfect :-) If you need help, ask me!!! 3 Adding content Between the heading (<h1>...</h1>) and the end body tag (), add some text. All the page content goes in between the body tags. <h1>welcome to Prof Sklar s home page!</h1> I m having so much fun learning HTML!

4 Adding a list Now add HTML tags to display an unordered list of five of your favorite movies. My fave flicks are: <ul> <li> Casablanca </li> <li> Diva </li> <li> Bringing Up Baby </li> </ul> Be sure to make the page user-friendly by putting in explanatory text telling what the list is (e.g., Here is a list of my five of my favorite movies: ). 5 Adding links A link, or hyperlink, in HTML provides a means for going from one page to another. The link has two components: one is the URL of the page that is being linked, and the other is the text (or image) that the user will click on in order to follow the link. Here, we ll just put text for the user to click on. The HTML tag for a link is: <a href=...url...>...click... </a> You need to replace the...url... with the location of the page you want to link and...click... with the text you want the user to click on in order to go to the linked page. <a href="http://www.amazon.com">amazon</a> Add links to each of the five items in your list of favorite movies. These could be links to the movies on Amazon or information on IMDB (http://www.imdb.com) or a trailer (e.g., http://www.apple. com/trailers) or some other relevant link. <ul> <li> <a href="http://www.tcm.com:80/tcmdb/title.jsp?stid=568"> Bringing Up Baby</a> </li> </ul> Save your changes. Reload the page in the browser and try clicking on your link. 6 Adding images The HTML tag to include an image in your document is different from the other tags we ve learned so far because it is a single tag; it does not have a begin tag and and end tag. The image tag is: <img src=...url...> Find an image that you like on the web and then find the URL of that image. Usually right-clicking on the image from the browser window will give you the option to Copy Image Location. Do that and then paste the image location into your text editor window. Then enclose the URL in the image tag.

<img src="http://g-ecx.images-amazon.com/images/g/01/gno/images/general/navamazonlogofooter._v264586593_.gif"> Save your changes. Reload the page in the browser and try clicking on your link. The image tag has one required parameter, src, which is set to the URL of the image you want to display. The image tag has several optional parameters. A useful parameter is called width which allows you to define the width of the image, in pixels. Using this parameter, you can have the browser resize the image to fit the width you specify. <img src= "http://g-ecx.images-amazon.com/images/g/01/gno/images/general/navamazonlogofooter._v264586593_.gif" width=200> Find an image to go with each of the movies on your list. Add an image tag to each list item. Set the width of all the images to be the same size. Again, save your changes. Reload the page in the browser and try clicking on your link. 7 Adding a table Tables provide ways of lining up information on an HTML page. The content of a table is organized in rows and columns. Rows extend horizontally. Columns extend vertically. See the illustration, below. column 1 column 2 column 3 row 1 A B C row 2 D E F row 3 G H J Tables are created using a series of tags. Table start and end tags <table>...</table> surround the whole table. Table rows start and end with: <tr>...</tr> Table columns start and end with: <td>...</td> The column tags are placed in between row tags. Below is the code to create a table with three rows and three columns: <table border=1> <tr> <td> A </td> <td> B </td> <td> C </td> </tr> <tr> <td> D </td> <td> E </td> <td> F </td> </tr> <tr> <td> G </td> <td> H </td> <td> J </td> </tr> </table> Note that the table tag shown above specifies one parameter, border. This is set to a numeric value like 0 for no border, 1 for a thin border, 2 for a thicker border, etc. Try entering the sample table above in your HTML file. Save and reload to make sure it works. Then modify the sample table to have two columns and five rows. Repeat the information from your list of movies in the table. The first column of each row should contain the title of the movie and whatever link you used above. The second column of each row should contain the image.

On-line references Introduction to HTML: http://www.w3.org/markup/guide/overview.html http://htmldog.com/guides/htmlbeginner/ Advanced HTML: http://www.w3.org/markup/guide/advanced.html http://htmldog.com/guides/htmlintermediate/ http://htmldog.com/guides/htmladvanced/ HTML reference: http://htmldog.com/reference/htmltags/ HTML Full Specification: HTML validator: http://www.w3.org/tr/html4/ (HTML version 4.01) http://validator.w3.org/ Mobile devices: http://www.w3.org/tr/2008/rec-mobile-bp-20080729/ (Mobile Web Best Practices 1.0) http://developer.apple.com/iphone/ (iphone sdk free download plus tutorials, videos and documentation) http://code.google.com/android/ (android sdk free download, documentation, etc)