Computer Science, asked by Rajkaurav4141, 1 year ago

Mention the suitable HTML tag and the attribute to insert an image named globe.jpg in the background of a webpage.

Answers

Answered by tannubastta
0

i know little messy sorry .I hope u got ur answer

Attachments:
Answered by Arslankincsem
1

The HTML tag and the attribute to insert an image in the background of a webpage is  

<body background="globe.jpg">

//Statements

</body>

For Example:

<!DOCTYPE html>

<html>

<body background="w3s.png">

<h1>Hello world!</h1>

<p><a href="https://www.w3schools.com">Visit W3Schools.com!</a></p>

<p>The background attribute is not supported HTML5. Use CSS instead.</p>

</body>

</html>

Note: The <body> background attribute is not supported by HTML 5. So to set an image in the background we use the CSS instead.

CSS Syntax to insert an image in the background of a webpage: <body style="background-image:url(globe.jpg)">

Similar questions