Document Structure: OBM255 Slide HTML 3
Document Structure: OBM255 Slide HTML 3
HTML
DOCUMENT
STRUCTURE
OBM255 Slide HTML 3
PRESENTED BY:
Compiled & Edited by: Madam Rozita Mengen (Sr. Lecturer)
2
Paired Tags
• Most HTML tags are paired, meaning that they
have a tag to indicate the beginning of a
command and another tag, with a forward slash
( / ) inside it, to indicate where that command
should end.
Tag Attributes
• Many HTML tags contain one or more attributes that can give extra
information to tell the browser how to interpret the tag. In most tags, the
attributes are optional.
• When a tag is using attributes, the name of the tag is written first,
followed by a space. Then the name of the attribute and an equal sign.
Next is the attribute itself enclosed in quotation marks.
• Single quotes can be used but double quotes are more common. Most
browsers will accept attributes without quotation marks but it is best to
include them as in the example below.
<html>
<title> MY FIRST WEBPAGE </title>
<body>
IN MY WEB PAGE I WILL SHARE MY PICTURES
</body>
</html>
8
Hypertext
• Hypertext is text with links. With hypertext the computer makes the
following such references as easy as turning the pages. Readers can
escape from the sequential organization of the pages.
Text editor
• Capable of creating plain text files by using Notepad for Windows and
Simple Text for Macintosh. If you using a word processor program then
you must save your files as plain ASCII text format.
9
LAB EXERCISES
• Before starting the lab exercises using Notepad
• Create a folder named <OBM255_Lab_Xs> in your
thumb drive and then transfer it into your Google drive
as a backup after each class.
• You must always save all your lab work in that folder.
10
OR
1. Go to windows bottom left hand side
2. Use the search option and type Notepad
3. Click on the Notepad ICON and start using it
11
Exercise (lab1)
• Open your Notepad & Web Browser on your screen
• Then type this on your Notepad screen
<html>
<title>MY WEB</title>
<body>
WELCOME TO MY FIRST WEBPAGE
</body>
</html>
• Save the file by pressing
• File => Save As “file1.html”
• Change the save as type from <Text Document>
to <All Files>
12
PARAGRAPHS <P>
THE OUTPUT AS SEEN FROM A WEB BROWSER
16
Exercises (lab3)
<html>
<body>
WELCOME TO MY FIRST WEBPAGE
<br>Everybody nowadays can have his or her own Web pages. <br> It can
be built as simply ABC as long you have the web browsers, text editors and
knowing the command of HTML.
</body>
</html>
HEADINGS
Lines of text, formatted differently from the body text that you may use to
structure the content of your Web page. Heading can be section titles,
page titles and so on. There are 6 levels of headings
HEADINGS
Open a new Notepad file
Exercises (lab4)
<html>
<body>
<h1> this is Heading1</h1>
<h2> this is Heading2</h2>
<h3> this is Heading3</h3>
<h4> this is Heading4</h4>
<h5> this is Heading5</h5>
<h6> this is Heading6</h6>
</body>
</html>
CHARACTER FORMATTING
You can control the appearance and arrangement of text on your web pages by
incorporating boldface, italics and other special text formatting. In using the text
formatting, you can combine more than one tag at the same time. This is
called nested tags or format.
Exercises (lab5)
<html>
<body>
This is <b> boldface text </b>
This is <i> italic text </i>
This is <u> underline text </u>
This is <small> smaller text </small>
This is <big> bigger text </big>
<br>
Superscript text can be found in 4<sup>4</sup>
Subscript text can be found in H<sub>3</sub>
This text is <strike>strikethrough</strike>
</body>
</html>
22
Go to website
https://stackoverflow.com/questions/18105152/alternative-for-blink
23
Go to website
https://stackoverflow.com/questions/18105152/alternative-for-blink
Copy and Paste below’s intruction
TEXT ALIGNMENT
Helps you to begin the new paragraph either should be aligned
to the left margin, right margin or center of the page
• Left margin is where the paragraph will start at the left margin
<P align= “left”>…</p>
TEXT ALIGNMENT
Open a new Notepad and do Lab6.
Exercises (lab6)
<html>
<body>
<center> WELCOME TO MY FIRST WEBPAGE</center>
<br>
</body>
</html>
Save As “file6.html” change type “All files”
27
Font control: Helps you to To control
the font either in size, face or color.
Font size <font size= “1,2,3,4,5,6,7”…</font> to set the size of any
text on a Web page. Its valid range are from 1 to 7.
Open a new Notepad file, do Lab7 & Save As “file7.html” change type “All
files”
Exercises (lab7)
<html>
<body>
<Font size=”1”> this is font size 1</font>
<Font size=”2”> this is font size 2</font>
<Font size=”3”> this is font size 3</font>
<Font size=”4”> this is font size 4</font>
<Font size=”5”> this is font size 5</font>
<Font size=”6”> this is font size 6</font>
<Font size=”7”> this is font size 7</font>
</body>
</html>
28
FONT CONTROL
Font color : You can have a color text by inserting the HTML color tags.
<font color= “red,blue…etc”>… </font>
Open a new Notepad file, do Lab8 & Save As “file8.html” change type
“All files”
Exercises (lab8)
<html>
<body>
<Font color=”red”> this text is red</font>
<Font color=”green”> this text is green</font>
<Font color=”yellow”> this text is yellow</font>
<Font color=”blue”> this text is blue</font>
<Font color=”purple”> this text is purple</font>
</body>
</html>
29
FONT CONTROL
FONT FACE : This tag will enable you to have the variety font text such
as Arial, Tahoma, Algerian…etc. <font face= “Arial,
Tahoma…etc”…</font>
Open a new Notepad file, do Lab9 & Save As “file9.html” change type
“All files”
Exercises (lab9)
<html>
<body>
<Font face=”Arial”> this is an Arial font</font>
<Font face=”Tahoma”> this is a Tahoma font</font>
<Font face=”Algerian”> this is an Algerian font</font>
<Font face=”Comic Sans MS”> this is a Comic Sans MS font</font>
</html>
</body>
30
FONT CONTROL
COMBINATION OF FONT TAGS: You can combine all the font tags in
one-text documents such as size, face and color.
Open a new Notepad file, do Lab & Save As “file10.html” change type
“All files”
Exercises (lab10)
<html>
<body>
<font size=”6”, font face=”Arial”, font color=”red”> WELCOME TO MY
FIRST WEB PAGE</font>
</body>
</html>
31
LAB 11 TO 29
Open your OBM255 : NOTES COMPLIATION
(6th Edition 2018)
Questions??
Recapturing…
Honestly ..
DID YOU do the lab 11 to 29 exercises
on your own?? OR DID NOT!!!
What have you achieved??
THE END