HTML body link Attribute
HTML <body> tag
Definition and Usage
The link attribute specifies the color of the unvisited links for a page.
Compatibility Notes
The link 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:link {color: #FF0000}</style>
In our CSS tutorial you can find more details about the
:link pseudo-class.
Syntax
<body link="color_value">
|
Syntax Example
Attribute Values
Value |
Description |
color_name |
Specifies the unvisited link color with a color name, like "red" |
RGB_value |
Specifies the unvisited link color with a RGB value, like "rgb(255,0,0)" |
Hex_value |
Specifies the unvisited link color with a hex value, like "#ff0000" |
Browser Support

The attribute is supported in all major browsers.
Example
<html>
<body link="red">
<a href="http://www.example.com/">An example link</a>
</body>
</html>
|
Try-It-Yourself Demos
body link
attribute example
Set the color of an unvisited link with the body link attribute
In CSS:
unvisited link style example
Set the color of an unvisited link with CSS.
HTML <body> tag
 |

|
|
See why there are 20,000+ Ektron integrations worldwide.
Request an INSTANT DEMO or download a FREE TRIAL today. |
|
|
|