gpt4 book ai didi

html - 将背景图像放在 Bootstrap 登录启动页面上

转载 作者:太空宇宙 更新时间:2023-11-04 13:36:49 25 4
gpt4 key购买 nike

我正在尝试自定义 Twitter Bootstrap 的初始登录页面。

我没有接触过 HTML,但我正在尝试编辑初始页面的背景。

这是我添加的所有 CSS:

html {
background: url("../img/bumpit_splash.png") no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}

发生的事情是初始页面的上半部分保留了它的白色背景,但下半部分获得了我试图替换它的背景图像的颜色。

提前感谢您的帮助。

最佳答案

如果没有预览很难判断,但我猜你的 <body>标签有白色背景,因为它是一个登录表单,所以它没有 <html> 高标记(您的视口(viewport))。

禁用 <body> 的背景颜色,或将其设为 100% 高并添加背景 this 而不是 html 元素。

关于html - 将背景图像放在 Bootstrap 登录启动页面上,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22994980/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com