HTML <body> vlinkAttribute
Example
Set the color of visited links in the document to red:
<p><a href="../index.html">Example</a></p>
<p><a href="../html/index.html">HTML Tutorial</a></p>
<p><a href="../html/index.html">HTML Tutorial</a></p>
Try it Yourself »
Browser Support
![]()
![]()
![]()
![]()
![]()
All major browsers support the vlink attribute.
Definition and Usage
HTML5 no longer supports the <body> vlink attribute. Please use CSS instead.
The vlink attribute of <body> is deprecated in HTML 4.01.
The vlink attribute specifies the color of visited links in the document.
Compatibility Notes
In HTML 4.01, the vlink attribute of the body element is deprecated; in XHTML 1.0 Strict DTD, the vlink attribute of the body element is not supported. Please use CSS instead.
CSS Syntax (in the <head> section): <style>a:visited {color: #FF0000}</style>
CSS Example: Set the color of visited links
In our CSS tutorial, you can find more about:visited pseudo-classknowledge.
Syntax
<body vlink="color_name|hex_number|rgb_number">
Attribute Value
| Value | Description |
|---|---|
| color_name | Specifies the font color with a color name value (e.g., "red"). |
| hex_number | Specifies the font color with a hexadecimal value (e.g., "#ff0000"). |
| rgb_number | Specifies the font color with an rgb code value (e.g., "rgb(255,0,0)"). |
HTML <body> Tag Other Extensions