背景附件:修复了在Safari上无法正常运行的问题 [英] background-attachment: fixed not working on Safari

查看:86
本文介绍了背景附件:修复了在Safari上无法正常运行的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在跨越浏览器100%的元素上运行了以下代码:

I've got the following code running on an element that spans 100% of the browser:

#section_white {
  background-attachment:fixed;
  background-image:url(image_url_here.jpg);
  background-position:100% 100%;
  background-repeat:no-repeat no-repeat;
  background-size:cover;
}

我需要做的是使图像跨过整个宽度浏览器,同时保持固定状态(从而允许内容在其顶部滚动)。

What I need to do is to have the image span the entire width of the browser, while remaining fixed (thereby allowing the content to scroll on top of it).

除了Safari以外,它似乎在所有浏览器上都可以工作-任何想法我都是

It seems to work on all the browsers except Safari - any ideas what I'm missing?

我尝试将元素高度最小高度设置为 100%,没有乐趣。

I've tried setting the element height and min-height to 100%, with no joy.

可以在此处看到演示页面的链接: http://oscarsarc.tinygiantstudios.co.za/adopt/adopt-nationwide/

A link to a demo page can be seen here: http://oscarsarc.tinygiantstudios.co.za/adopt/adopt-nationwide/

推荐答案

结果表明,不再支持Windows的Safari浏览器(我怎么错过了?!),而我使用的版本太旧了,无法使用。使用OSX / Safari,事情看起来很桃红(根据Benjamin)

Turns out Safari for Windows is no longer supported (how did I miss this?!) and the one I'm using is far too old to be useful. Using OSX / Safari, things look peachy (according to Benjamin)

这篇关于背景附件:修复了在Safari上无法正常运行的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆