Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to set up background background Picture by css

2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly shows you "css how to set background background picture", the content is easy to understand, clear, hope to help you solve your doubts, the following let the editor lead you to study and learn "css how to set up background background picture" this article.

1. No equipment installation, tiling mode, objects covered with background pictures.

1). Example CSS code:

.logo {width:405px;height:200px; bac kilogram round: url (/ / www.css5.com.cn/imgthink2015/logo.gif)}

Description: directly set the equipment background backing style to introduce pictures, do not set the repeated repeat attribute value.

2), html instance code

3) screenshot of the effectiveness of the back round set picture

No backup tiling door path picture is configured as a background tiling object

2. Pictures of non-frequent backers

1), example CSS code

.logo {width:405px;height:200px; bac kilogram round: # F00 url (/ / www.css5.com.cn/imgthink2015/logo.gif) no-repeat 20px 30px}

Here at the same time configure the background color and backing picture, and configure the no-repeat 20px 30px image to reveal the performance, interval left 20px, interval 30px.

2). Example html code:

3) screenshot of the effectiveness of css bac kilogram round

Div css instance simultaneously sets backing color and backing image unyielding screenshot of instance

2. Configure background image tiling (from left to right)

1). CSS code of tiling instance with the degree of background image.

.logo {width:405px;height:200px; bac kilogram round: # F00 url (/ / www.css5.com.cn/imgthink2015/logo.gif) repeat-x 0 40px}

Note: set the repeat-x image as the backing water clear light shop, 0 40px, set the picture to the top interval 40px beginning degree tile

2), HTML code:

3). Screenshot of an example

Screenshots of tiling examples backed by pictures

3. Set up the equipment, set up the picture and tile the scene vertically (from top to bottom).

1), div css sets the background background image vertical tile instance CSS code

.logo {width:405px;height:200px; bac kilogram round: # F00 url (/ / www.css5.com.cn/imgthink2015/logo.gif) repeat-y 60px 0}

Note: repeat-y setup equipment backup picture tiled from top to bottom, picture distance left 60px

2), example html code

CSS5

3). Screenshot of bac kilogram round instance

Css picture as a screenshot of vertical tiling from top to bottom of the backer.

The above is all the contents of the article "how to set up background background pictures in css". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report