HTML body vlink Attribute
HTML <body> tag
Definition and Usage
The vlink attribute specifies the color of the visited links for a page.
When a link has been used/visited earlier, the color changes to indicate that the
link has been visited.
Compatibility Notes
The vlink 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:visited {color: #00FF00}</style>
In our CSS tutorial you can find more details about the
:visited pseudo-class.
Syntax
<body vlink="color_value">
|
Syntax Example
Attribute Values
Value |
Description |
color_name |
Specifies the visited link color with a color name, like "red" |
RGB_value |
Specifies the visited link color with a RGB value, like "rgb(255,0,0)" |
Hex_value |
Specifies the visited link color with a hex value, like "#ff0000" |
Browser Support
The attribute is supported in all major browsers.
Example
<html>
<body vlink="red">
<a href="/default.asp">W3Schools</a>
</body>
</html>
|
Try-It-Yourself Demos
body vlink
attribute example
Set the color of an visited link with the body vlink attribute
In CSS:
visited link style example
Set the color of an visited link with CSS.
HTML <body> tag
…
|