Chap 02a - HTML and Multimedia On The Web
Chap 02a - HTML and Multimedia On The Web
Chap 02a - HTML and Multimedia On The Web
Prepared for:
CSC264 – Introduction to Web and
Mobile Application
OVERVIEW OF THIS CHAPTER
Text Layout:
The following tags or attributes can be used to change how
the text is aligned:
HTML STRUCTURE: TEXT
Text Layout:
HTML STRUCTURE: DIVISION
Div Tag:
The syntax for font
tag:
<div> content </div>
Unordered Lists:
Allows you to list down items without any form of
ordering
The syntax for unordered list is:
<ul> content </ul>
Each item that needs to be listed down will have the following
syntax:
<li> content </li>
HTML STRUCTURE: LISTS
Unordered Lists (Style Attribute):
To define the style of the marker (bullet points), a style attribute
can be added
Style Description
list-style-type:disc The list items will be marked with bullets
(default)
list-style-type:circle The list items will be marked with circles
list-style-type:square The list items will be marked with squares
list-style-type:none The list items will not be marked
HTML STRUCTURE: LISTS
Ordered Lists:
Allows you to list down items in order
(numerically)
The syntax for ordered list is:
<ol> content </ol>
Each item that needs to be listed down will have the following
syntax:
<li> content </li>
HTML STRUCTURE: LISTS
type="I" The list items will be numbered with uppercase roman numbers
type="i" The list items will be numbered with lowercase roman numbers
HTML STRUCTURE: LISTS
Description Lists:
Allows you to list down items with a description of each
item
The syntax for description list is:
<dl> content </dl>
Each item name or term that is listed down will have the following
syntax:
<dt> content </dt>
What is MULTIMEDIA?
Why is it used
on a web
page?
Graphics (Images):
Most commonly used formats for graphics are:
1. JPEG (Joint Photographic Expert Group)
WHY?
Often used for scanned photographs, artworks,or other
images that include smooth colour variations
The files have *.jpg extensions.
Graphics (Images):
Other graphics format
include:
Acronym Name File Extension
PNG Portable Network *.png
Graphics
TIFF Tagged Imaged File *.tif
Format
PCX PC Paintbrush *.pcx
BMP Bitmap *.bmp
MULTIMEDIA ON THE WEB
Graphics (Images):
To add an image as content on a web
page,
the img element is used (NO end tag)
Attribute Result
File Format Audio Type
autoplay Plays sound when the page is viewed
MP3 audio/mpeg
controls Shows a slider that lets the user control the
sound (Its width and length can be changed Ogg audio/ogg
using CSS)
Wav audio/wav
loop Plays the sound repeatedly
MULTIMEDIA ON THE WEB
Embedding Audio: You can use style
attribute to customize
your controls
Other attributes that can be used to control the way the sound
is played are shown below:
Attribute Result
File Format Video Type
autoplay Plays video when the page is viewed
MP4 video/mp4
controls Shows a slider that lets the user control the
video (Its width and length can be changed using WebM video/webm
CSS) Ogg video/ogg
loop Plays the video repeatedly
MULTIMEDIA ON THE WEB
You can use style attribute
Embedding Video: to customize your controls
Provide alternatives:
The browser will use the first recognized
format.
HTML: LINKS
Links:
Allow users to get from one web page to another
In HTML, a link is known as Hyperlink
Links:
Uses the anchor
tag:
<a> link text </a>
table
<table>
row <tr>
cell <td> cell <td>
HTML:
TABLES
Inline Style
Sheet
HTML:
TABLES
cel cel
l l
HTML: TABLES
cel cel
l l
rowspan is used when you
have uneven number of cel
l
row in a column cel
l
cel
l
HTML: TABLES