w3resource
HTML exercises

CSS Properties: How to set different background properties in one declaration?

Go to Exercise page

Solution:

HTML Code:

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" /> 
<title>How to set different background properties in one declaration</title>
<style>
body { 
margin-top: 300px;
background: #6699FF no-repeat center/80% url("https://www.w3resource.com/images/w3resourcelogo.gif"); 
}
</style>
</head>
<body>
<p>w3resource Tutorial</p>
</body>
</html>

Live Demo:

See the Pen background-answer by w3resource (@w3resource) on CodePen.

See the solution in the browser

Supported browser

Firefox logo Chrome logo Opera logo Safari logo Internet Explorer logo
Yes Yes Yes Yes No

Go to Exercise page

What is the difficulty level of this exercise?



New Content: Composer: Dependency manager for PHP, R Programming


bedava porno