Web Design 251023
Web Design 251023
31
HTML Tables
32
HTML Tables
33
HTML Tables
34
Spanning Cells
35
Describing table content
36
Grouping Rows & Columns
37
Exercise
38
HTML LINKS
39
HTML Links
40
Absolute Urls
■ Absolute URLs provide the full URL for the document starting from the root directory,
including the protocol, domain name and pathname.
■ <a ></a>
41
Absolute Urls
/home/jono/photos/ D:/Data/Final/Cars
42
Relative Urls
■ Relative URLs describe the pathname to a file relative to the current document. It
does not require the protocol or domain name. Relative URLs can be used when
linking to another document on your website.
■ <a ></a>
43
Relative Urls
Move to the photos folder starting from home/ Move to the Cars file starting from Data/
=> jono/photos/ => Final/Cars
44
Relative Urls
../
../
../
../
../
Move to the lib folder starting from photos/ Move to the Cars file starting from Con/
=> ../../Data/Final/Cars
=> ../../../usr/lib/
45
Absolute Urls vs Relative Urls
Where is
Ublock ?
46
Absolute Urls vs Relative Urls
Where is
Ublock ?
47
Absolute/Relative Urls Exercise
48
HTML Links Don’ts
■ Do not use “\”, instead use “/”. \ works only on Windows PCs
■ Do not start with the drive name eg.
■ Do not start with file:// eg
file://Users/kofimokome/Documents/Web_design/website/images/logo.jpeg
49
Linking withing a directory
■ If both files are in the same directory, just put the name of file in the href attribute
50
Linking to a lower directory
■ If the file is in a lower directory, add the directory name, followed by a / then the file
name
51
Linking to a lower directory
■ If the file is in a lower directory, add the directory name, followed by a / then the file
name
52
Linking to a higher directory
■ If the directory is one step higher, just ”../” followed by the file name
53
Linking to a higher directory
■ If the directory is two steps higher, just ”../../” followed by the file name
54
Linking to a specific point on a page
55
Opening a link on a new tab
56
Mail and Telephone links
57
Exercise
■ Create index.html
■ Write the HTML
■ Add links to the recipe
and about us page
■ Note: Home is not blue
58
Exercise
■ Create recipes.html
■ Write the HTML
■ Add links to the home
and about us page
■ Note: Recipes is not blue
59
Exercise
■ Create about.html
■ Write the HTML
■ Add links to the recipe
and home page
■ Note: About Us is not
blue
60
Exercise - Hint
61