Can multiple background pictures be added to html?
Whether html can add multiple background pictures, in view of this question, this article introduces the corresponding analysis and answer in detail, hoping to help more partners who want to solve this problem to find a more simple and feasible way.
Html can add multiple background images. In html, you can set multiple background images for a container through background-image or background, that is, put different background images into only one block element; syntax "background:url (picture address), url (address)."
The operating environment of this tutorial: windows7 system, CSS3&&HTML5 version, Dell G3 computer.
In html, you can set multiple background images for a container through background-image or background, that is, you can put different background images into only one block element.
First of all, let's look at the grammar:
Background: [background-image] | [background-origin] | [background-clip] | [background-repeat] | [background-size] | [background-attachment] | [background-position]
The url of multiple background images can be separated by commas. If there are multiple background images and there is only one other attribute (for example, there is only one background-repeat), then all background images apply this property value.
Let's look at an example:
Body {background-image: url (https://image.flaticon.com/icons/svg/748/748122.svg), url (https://images.unsplash.com/photo-1478719059408-592965723cbc?ixlib=rb-1.2.1&auto=format&fit=crop&w=2212&q=80); background-position: center, top; background-repeat: repeat, no-repeat; background-size: contain, cover) } the answer to the question about whether html can add multiple background pictures is shared here. I hope the above content can be of some help to you. If you still have a lot of doubts to be solved, you can follow the industry information channel for more related knowledge.