Html4newbies
Put your hands into html and php
Home
Privacy
About
Contact

Hosting Links
Hosting
Free Php Snippets
Php Snippets 1
Php Snippets 2
A - anchor


A - anchor

Description :

The A tag is for defining anchors and links. An anchor is a specific place in a document whereas a link is a hypertext link which when selected takes you to an anchor or another document.

Syntax

<A NAME="anchorName>....</A>
<A HREF="URL" TARGET="windowName"> .... </A>


Attributes

To use the A tag (remember all HTML tags are enclosed in angled brackets) as an anchor, you need to use the attribute NAME. It is important that you do not nest this tag. Whatever is between the opening and closing tags will be a selectable link or anchor.

The HREF attribute is specifying the destination URL for the link, if a new document is being linked to. If it is a link to an anchor in the same document, then the value of the HREF attribute needs to be the name of the anchor to which to scroll to, preceeded by a # symbol. You can scroll to an anchor in a new document by specifying the URL followed by # followed by the anchor name.

The TARGET attribute can be used to open the link in a specific window, either in a frameset or a new window which you want to asign a name to. There are some special values for the TARGET attribute:

_blank opens link in new unnamed window
_parent opens link in the parent window of the one displaying the current document
_self opens the link in the same window as the one in which the link was clicked
_top opens the link in the full body of the current window. This can be used to make sure the new document takes over the full window, even if the original was displayed in a frame.
Copyright © 2002-2017 Html4newbies - HarlandScripts.com NetWork