/* Background-Image: Sets the background image of an element */
background-image: url("clashingcode");
/* Background-Position: The position property is mainly used to specify the positioning of the image */
background-position: right top;
/* Background-Repeat: Defines how a specified background image is repeated. The repeat-x value will repeat the image horizontally(x-axis) while the repeat-y value will repeat the image vertically(y-axis) */
background-repeat: repeat-x;
/* Background-Attachment: specifies the kind of attachment of the background image(scroll with the content or be fixed respect the container). */
background-attachment: scroll;
/* Background-Color: Sets the background color of an element */
background-color: blue;
/* Background: Shorthand Property */
background: background-color background-image background-repeat background-attachment background-position;
body {
background: lightblue url("img_tree.gif") no-repeat fixed center;
}
body {
height: 100vh;
background: url(relative path or url in double quotes) | linear-gradient()
background-size: cover | contain | any unit value e.g. 1500px;
background-attachment: fixed | local | scroll;
background-position: x-offset(values:left,center,right) y-offset(values:top,center,bottom);
/* or single value for both x & y-offset */
background-repeat: repeat (enabled by default) | no-repeat;
/* some of them will only work provided height of the container */
/* That's pretty much it folks */
/* I can't cover details of each value. You'd have to search it */
}
/*This is an example*/
.example {
background: url("Yeet");
}
Code Example |
---|
Css :: background-image linear-gradient url |
Css :: display in css |
Css :: css make bottom of the div triangle |
Css :: hr vertical en html |
Css :: @container |
Css :: what css vmin |
Css :: input of type radio css |
Css :: elementor vertical line |
Css :: animated background css |
Css :: css bullet using ::before |
Css :: wave css |
Css :: css media query overflow |
Css :: add border to png outline css |
Css :: responsive gradient background css |
Css :: nibabel ValueError: w2 should be positive, but is |
Css :: matrix css |
Css :: css materialize |
Css :: line icon css |
Css :: css button generator |
Css :: select first 5 child css |
Css :: zoom in to picture on html css |
Css :: import scss |
Css :: css speak |
Css :: rgba color css |
Css :: send element to center of div |
Css :: flexbox elements |
Css :: control one swiper with other |
Css :: How to make website responsive for safari |
Css :: how to disable site anchor |
Css :: como hacer que me queden los nombres dentro de un formulario css |