Professional Documents
Culture Documents
HTML Links
Objectives:
HTML Links
HTML links are hyperlinks. You can click on a link and jump to another document.
A link does not have to be text. It can be an image or any other HTML element.
The link text is the visible part, clicking on the link text will send you to the specified
address.
Try this:
<html>
<body>
</body>
</html>
Absolute and relative Links
1. An absolute URL points to another web site ex.
href="http://www.yahoo.com” A full web address
2. A relative URL points to a file within a web site without http://www....
Such as:
<a href="html_images.asp">HTML Images</a>
Or ex. href="/themes/theme.css" if the page in a folder in the
same web site.
This example will open the linked document in a new browser window/tab:
Try this
<a href="http://www.bau.edu.jo/" target="_blank">Visit BAU!</a>
Going from one Location into another within the Same Web Page
<html> <body>
<h2>Chapter 1</h2>
<h2>Chapter 2</h2>
<h2>Chapter 3</h2>
<p>This chapter explains ba bla bla</p>
<h2>Chapter 5</h2>
<h2>Chapter 6</h2>
</body>
</html>
Image as Link
Try this
<a href=" >
</a>
Image Maps
<area shape ="rect|circle|polygon" coords="value">
Value Description
Try this
<html>
<body>
<map name="planetmap">
</map>
</body></html>
<a href="mailto:asmakhtoom@yahoo.com?Subject=Hello
again">SendMail</a>
</p></body></html>
TASKS
Q1 .Write the code to view the next page.
News page: include nested lists (orderd and unordered list) about any news.
Q2. Write the code to view the next page. Each link open
location as follow:
Pictures: open your computer picture folder.
Social: open html page contain three ordered list with three images about social
media sites.