![]() |
<body> Defines the document's body. The The Note: There can only be one |
Example:
HTML
<html>
<head>
<title>Title of the document</title>
</head>
<body>
<h1>This is a heading</h1>
<p>This is a paragraph.</p>
</body>
</html>
Follow the Example.
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
body {
background-image: url(https://horje.com/avatar.png);
}
</style>
</head>
<body>
<h1>Hello world!</h1>
<p><a href="https://horje.com">Visit Horje.com!</a></p>
</body>
</html>
Follow the Example.
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
body {
background-color: #E6E6FA;
}
</style>
</head>
<body>
<h1>Hello world!</h1>
<p><a href="https://horje.com">Visit Horje.com!</a></p>
</body>
</html>
Follow the Example.
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
body {
color: green;
}
</style>
</head>
<body>
<h1>Hello world!</h1>
<p>This is some text.</p>
<p><a href="https://horje.com">Visit Horje.com!</a></p>
</body>
</html>
Follow the Example.
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
a:link {
color: #0000FF;
}
</style>
</head>
<body>
<p><a href="https://horje.com">Horje.com</a></p>
<p><a href="https://horje.com/html/">HTML Tutorial</a></p>
</body>
</html>
Follow the Example.
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
a:active {
color: #00FF00;
}
</style>
</head>
<body>
<p><a href="https://horje.com">Horje.com</a></p>
<p><a href="https://horje.com/html/">HTML Tutorial</a></p>
</body>
</html>
Follow the Example
Example:
HTML
<!DOCTYPE html>
<html>
<head>
<style>
a:visited {
color: #FF0000;
}
</style>
</head>
<body>
<p><a href="https://horje.com">Horje.com</a></p>
<p><a href="https://horje.com/html/">HTML Tutorial</a></p>
</body>
</html>
Follow the Example.
Example:
HTML
<style>
body {
display: block;
margin: 8px;
}
body:focus {
outline: none;
}
</style>
<body>
The content of the document......
<p>Change the default CSS settings to see the effect.</p>
</body>
Read Full: | HTML Tag |
Category: | Web Tutorial |
Sub Category: | HTML Tag |
Uploaded by: | Admin |
Views: | 116 |
Reffered: https://www.w3schools.com/tags/tag_body.asp