Professional Documents
Culture Documents
Web Technologies: HTML Basics
Web Technologies: HTML Basics
HTML Basics
Wasif Hamdani
Internet?
2
History
3
Uses of the Internet
Web Technologies?
• Since computers can’t communicate with each
other like the way people do, instead they
require codes.
6
Web Components
7
URI, URL, URN
8
Client/Server Structure of the Web
• Web content lives on web servers.
12
HTML
• HTML
– Stands for Hyper Text Markup Language
– HyperText
• The text that has reference to another text document
– Markup language
• Language that is both machine and human readable
13
HTML
• Markup language
– Defines the style and structure of a document so that
a computer knows how you want that document to
appear.
• HTML Page
– HTML pages are text documents containing HTML
structure
14
15
16
Example: HTML Structure
17
Example: HTML Structure
18
HTML Structure
19 2/20/2020
HTML Structure
20 2/20/2020
HTML Structure
21 2/20/2020
HTML Structure
22
HTML Structure
paragraph o
f text
appears bet
ween these
<p> and </p
> tags.
23 2/20/2020
HTML Tags
24 2/20/2020
HTML Tags
25 2/20/2020
Attributes
26
HTML Tags
27
Body & Title
28
Body & Title
29
Body & Title
30
Headings
31
Heading
• Example code
32 2/20/2020
Paragraph
33
Bold and Italic
• Bold
– By enclosing words in the tags <b> and </b> we can
make characters appear bold.
• Italic
– By enclosing words in the tags <i> and </i> we can
make characters appear italic.
• Example
34 2/20/2020
Line Breaks & Horizontal Rules
• Line Break
– Just like <p></p> the line break <br /> breaks line and
starts new line
– Example
<p>The Earth<br />gets one hundred tons heavier
every day<br />due to falling space dust.</p>
• Horizontal Rule
– Just like <br /> it separates lines by placing a solid line in
between paragraphs
<p>Venus is the only planet that rotates
clockwise.</p>
<hr />
<p>Jupiter is bigger than all the other planets
combined.</p>
35
Line Breaks & Horizontal Rules
36
Blockquote
• Blockquote
– The <blockquote> tag specifies a section that is
quoted from another source.
– Browsers usually indent <blockquote> elements.
37
Abbreviation or Acronym
• Abbreviation or an acronym
– Use an abbreviation or an acronym, when you like to
add shortened versions of something else
38
Example HTML Document
39 2/20/2020
Example HTML Page
40
Lists
41
List
• Ordered List
– <ol>
• The ordered list is created with the <ol> element.
– <ul>
• The unordered list is created with <ul> element.
– <li>
• Each item in the list is placed between an opening <li> tag
• and a closing </li> tag. (The li stands for list item.)
– Browsers indent lists by default.
42
List
• Example
43
List
• Definition List
– The definition list is created with the <dl> element
and usually consists of a series of terms and their
definitions.
44
Example HTML document
• Summary
45 2/20/2020
Link
• Hyperlink
– A hyperlink is a word, phrase, or image that you can
click on to jump to a new document or a new section
within the current document.
– Example
• <a href="url">link text</a>
46
Hyperlink
• Example
47
Hyperlink
48
Hyperlink
49
Hyperlink
50
Images
51
Figure & Figure Caption
52
Images
53
Tables
54
Tables
55
Tables
56
Tables
57
Tables
58
HTML Forms
• Each form control is given a name, and the text the user types in
or the values of the options they select are sent to the server.
59
HTML Form Structure
• <form>
– This element should always carry the action attribute and will
usually have a method and id attribute too.
• Action
– Every <form> element requires an action attribute. Its value is
the URL for the page on the server that will receive the
information.
• Method
– Forms can be sent using one of two methods: get or
post.
60
HTML FORMS
61
HTML FORMS
63
Grouping Form Elements
The <legend> element can come
You can group related form directly after the opening <fieldset>
controls together inside the tag and contains a caption which
<fieldset> element helps identify the purpose of that
group of form
controls.
64
HTML Form Example
65
HTML Page
66
HTML Page – Visual Studio
67
HTML Page – Visual Studio
68
HTML Page – Visual Studio
69
HTML Page – Visual Studio
70
HTML Page – Visual Studio
71
HTML Page – Visual Studio
72
HTML Page – Visual Studio
73
HTML Page – Visual Studio
74
HTML Page – Visual Studio
75
HTML Page – Visual Studio
76
Question(s)?
77
Thank you
78