HTML a tag

The HTML <a> i.e. Anchor tag, defines the hyperlink which is basically linking one page to another page in the Website. The destination of the linking page and its value is determined by href attribute.

There are three different version for this HTML <a> tag

  • Visited link
  • Unvisited link
  • Active Link
Note : Each type of link has default CSS with it showing the status of the HTML <a> tag in web page.




Read more HTML CSS and other web development tutorials at Tutorialmines now!

Attributes that are placed alongside with HTML <a> tag are

[table caption=”List of HTML tags not supported in HTML5″ width=”800″ colwidth=”100|300|400″ colalign=”left|center|center”]
Name, Value, Information
Charset,char encoding,Used to specify the character set (Not Supported in HTML5)
Coords,Coordinates,Marking the coordinates of the link (Not supported in HTML5)
Download,Filename,Name of the file to be downloaded when clicked
href,URL, defining the path the link should take when clicked
hreflang,language code, Showing the language of the linked page
media,media query, attaching tag to media devices (New in HTML 5)
name,section of the name, name of the anchor tag (Not supported in HTML5)
rel, alternate author bookmark help license next nofollow noreferrer prefetch prev search tag, Used as showing the relationship between two linked pages or document
rev,text,set the relationship between current and linked document (not supported in HTML5)
shape,rect circle poly default, used to specify the link shape (Not supported in HTML5)
target,_blank _parent _self _top, How & where to open the new link in the browser window?
type,media type, Specify the media attached to the link
[/table]

Tip : href attribute must be present for other attributes to work i.e download, hreflang, rel, media, target, and type smoothly!

Default CSS settings for html <a> tag


a:link, a:visited {
color: (internal value);
text-decoration: underline;
cursor: auto;
}

a:link:active, a:visited:active {
color: (internal value);
}

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *