7. links & anchors

21
Links & Anchors

Upload: naira-varosyan

Post on 13-Jan-2015

149 views

Category:

Education


2 download

DESCRIPTION

 

TRANSCRIPT

Page 1: 7. links & anchors

Links & Anchors

Page 2: 7. links & anchors

An anchor is a special tag that does not

determine the appearance of text.

Page 3: 7. links & anchors

It indicates a connection between

the current document and some

other entity.

Page 4: 7. links & anchors

There are several types of anchor,

but all of them use the <A> ... </A>

tag

Page 5: 7. links & anchors

Start tag: required, End tag: forbidden

Page 6: 7. links & anchors

The hypertext reference appears in

the text as a highlighted hotspot

word or phrase; often coloured, and usually

underlined.

Page 7: 7. links & anchors
Page 8: 7. links & anchors

The format for a target is:

<A NAME="target_name">hot spot text</A>

Page 9: 7. links & anchors

target_name is a symbolic name that can

be referenced in other anchors;

Page 10: 7. links & anchors

href attribute means "hypertext

reference";

Page 11: 7. links & anchors

the hash sign (#) means that it is an internal reference.

Clicking on it takes you to the target identified by

target_name.

Page 12: 7. links & anchors

Links between files

Page 13: 7. links & anchors

By far the most common use of a link is to retrieve

another Web resource

Page 14: 7. links & anchors

However, authors may insert links in their documents.

Page 15: 7. links & anchors

Links express other types of relationships have one or more link types specified in their source anchor.

Page 17: 7. links & anchors

This attribute describes the relationship from the current document to the anchor specified by the href attribute.

rel

Page 18: 7. links & anchors

This attribute is used to describe a reverse link from the anchor

specified by the href attribute to the current document.

rev

Page 19: 7. links & anchors

This attribute specifies the character encoding of the resorce designated by the

link.

charset

Page 20: 7. links & anchors

Consider two documents A and B.

Document A: <LINK href="docB" rel="foo">

Has exactly the same meaning as:Document B: <LINK href="docA" rev="foo">

Both attributes may be specified simultaneously.

Page 21: 7. links & anchors

to see more examples : go to the learnit.am