0% found this document useful (0 votes)
5 views1 page

HTML Coding Examples

The document provides HTML coding examples demonstrating various attributes and tags. It includes examples of background attributes, link colors, and the use of the <center> and <hr> tags. Each example is presented with a complete HTML structure for clarity.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views1 page

HTML Coding Examples

The document provides HTML coding examples demonstrating various attributes and tags. It includes examples of background attributes, link colors, and the use of the <center> and <hr> tags. Each example is presented with a complete HTML structure for clarity.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

HTML Coding Examples

1. Background Attributes
<!DOCTYPE html>
<html>
<head>
<title>Background Attributes Example</title>
</head>
<body bgcolor="lightblue" background="background.jpg">
<h1>This page has a background color and image</h1>
<p>The background is light blue with an image.</p>
</body>
</html>

2. Link, Alink and Vlink Attributes


<!DOCTYPE html>
<html>
<head>
<title>Link Color Example</title>
</head>
<body link="blue" alink="red" vlink="purple">
<h2>Link, Alink, and Vlink Example</h2>
<a href="https://www.google.com">Visit Google</a><br>
<a href="https://www.example.com">Visit Example</a>
</body>
</html>

3. <center> and <hr> Tag


<!DOCTYPE html>
<html>
<head>
<title>Center and HR Tag</title>
</head>
<body>
<center>
<h1>This is Centered Heading</h1>
<p>This paragraph is also centered.</p>
</center>
<hr>
<p>This paragraph is below a horizontal line.</p>
</body>
</html>

You might also like