HTML body alink Attribute

Definition and Usage

The alink attribute specifies the color of the active links for a page.
When a link is activated (clicked), the color changes to indicate that the link has been activated. This is called an active link (or in this case, alink).
The active link color is seldom noticeable unless the target frame of the link is a new/different frame.

Compatibility Notes

The alink attribute of the body element was deprecated in HTML 4.01 and is not supported in XHTML 1.0 Strict DTD.
Use CSS instead.
CSS syntax (in <head>): <style>a:active {color: #0000FF}</style>


<body alink="color_value">

Syntax Example

<body alink="red">

Attribute Values

Value Description
color_name Specifies the active link color with a color name, like "red"
RGB_value Specifies the active link color with a RGB value, like "rgb(255,0,0)"
Hex_value Specifies the active link color with a hex value, like "#ff0000"

Browser Support

The attribute is deprecated, but supported in all major browsers.


<body alink="red">
<a href="/default.asp" target="_blank">welcome</a>
HTML body alink Attribute Reviewed by 1000sourcecodes on 08:46 Rating: 5
Powered by Blogger.