当前位置:网站首页>Two methods for full screen adaptation of background pictures, background size: cover; Or (background size: 100% 100%;)
Two methods for full screen adaptation of background pictures, background size: cover; Or (background size: 100% 100%;)
2022-07-08 01:07:00 【Intelligent control and optimization decision Laboratory of Cen】
background: #000 url(img1.jpg) no-repeat fixed center center;
background-size: cover; perhaps (background-size: 100% 100%;)
Pay attention to writing well background Then write background-size, Otherwise it will be useless , Bear in mind , I wasted more than an hour here
100% and cover The difference between the two is roughly as follows
background-size in ,100% and cover Are used to enlarge or zoom the image to fit the entire container
background-size:100% 100%;--- Fill up in proportion to the container , Image distortion ;

background-size:cover;--- Enlarge the background image to fit the element container , The scale of the picture is the same , But be careful , The part beyond the container may be cut off .

I personally feel that background-size:100%,100%; Better effect
Original picture

边栏推荐
- NTT template for Tourism
- Share a latex online editor | with latex common templates
- Recommend a document management tool mendely Reference Manager
- Langchao Yunxi distributed database tracing (II) -- source code analysis
- 完整的模型训练套路
- New library online | information data of Chinese journalists
- Analysis of 8 classic C language pointer written test questions
- 手写一个模拟的ReentrantLock
- tourist的NTT模板
- 12.RNN应用于手写数字识别
猜你喜欢

DNS series (I): why does the updated DNS record not take effect?

Share a latex online editor | with latex common templates

图像数据预处理

letcode43:字符串相乘

Su embedded training - Day9

Where is the big data open source project, one-stop fully automated full life cycle operation and maintenance steward Chengying (background)?

130. Surrounding area

12.RNN应用于手写数字识别

3. MNIST dataset classification

利用GPU训练网络模型
随机推荐
基于微信小程序开发的我最在行的小游戏
Introduction to paddle - using lenet to realize image classification method II in MNIST
13.模型的保存和载入
手机上炒股安全么?
They gathered at the 2022 ecug con just for "China's technological power"
AI zhetianchuan ml novice decision tree
String usage in C #
10.CNN应用于手写数字识别
13.模型的保存和載入
Service mesh introduction, istio overview
Langchao Yunxi distributed database tracing (II) -- source code analysis
STL--String类的常用功能复写
C# ?,?.,?? .....
Authorization code of Axure rp9
8. Optimizer
完整的模型训练套路
Class head up rate detection based on face recognition
Analysis of 8 classic C language pointer written test questions
How to use education discounts to open Apple Music members for 5 yuan / month and realize member sharing
新库上线 | 中国记者信息数据