gpt4 book ai didi

html - 网页在 iOS 7 中崩溃

转载 作者:太空宇宙 更新时间:2023-11-03 17:44:43 24 4
gpt4 key购买 nike

更新:我想通了。 iOS 7 不喜欢 vh 单位。所以我转而使用 JavaScript 来检测浏览器高度,它现在可以在 iOS 7 上运行。

我制作了一个网站,该网站适用于我测试过的所有设备,但 iOS 7 的 iPhone 除外。整个页面崩溃,并出现这种疯狂的迪斯科闪烁现象。

iOS 7 上的结果可以在这里看到:http://morten-hauge.com/diverse/ios7_fail.MOV

如果我删除我的 CSS 文件,页面将按照您对没有 CSS 的页面的预期方式加载。

*
{
margin: 0;
padding: 0;
}

a, a img
{
text-decoration: none;
border-style: none;
}

#splash-container
{
position: fixed;
top: 40px;
right: 40px;
-webkit-backface-visibility: hidden;
}

img.splash
{
display: block;
width: 100px;
height: 100px;
margin: 0 0 20px 0;

transition-duration: .2s, .2s;
transition-timing-function: linear, ease-in;

-ms-transition-duration: .2s, .2s;
-ms-transition-timing-function: linear, ease-in;

-webkit-transition-duration: .2s, .2s;
-webkit-transition-timing-function: linear, ease-in;

-o-transition-duration: .2s, .2s;
-o-transition-timing-function: linear, ease-in;

-moz-transition-duration: .2s, .2s;
-moz-transition-timing-function: linear, ease-in;
}

img.splash:hover
{
transform: scale(1.1);
-ms-transform: scale(1.1);
-webkit-transform: scale(1.1);
-o-transform: scale(1.1);
-moz-transform: scale(1.1);
cursor: pointer;
}

#splash1-mobil
{
display: none;
}


.pil
{
width: 40px;
height: 40px;
margin: 160px auto 0 auto;
padding: 0;
position: relative;

animation: arrowAni 1.5s ease-in-out infinite;
-webkit-animation: arrowAni 1.5s ease-in-out infinite;
-moz-animation: arrowAni 1.5s ease-in-out infinite;
-o-animation: arrowAni 1.5s ease-in-out infinite;
-ms-animation: arrowAni 1.5s ease-in-out infinite;

-webkit-perspective: 1000;
-webkit-backface-visibility: hidden;
}

img.pil
{
-webkit-backface-visibility: hidden;
}

a img.pil
{
-webkit-backface-visibility: hidden;
}

@keyframes arrowAni
{
0% { bottom: 10px;}
50% { bottom: 30px;}
100% { bottom: 10px;}
}

@-webkit-keyframes arrowAni
{
0% { bottom: 10px;}
50% { bottom: 30px;}
100% { bottom: 10px;}
}

@-moz-keyframes arrowAni
{
0% { bottom: 10px;}
50% { bottom: 30px;}
100% { bottom: 10px;}
}

@-o-keyframes arrowAni
{
0% { bottom: 10px;}
50% { bottom: 30px;}
100% { bottom: 10px;}
}

@-ms-keyframes arrowAni
{
0% { bottom: 10px;}
50% { bottom: 30px;}
100% { bottom: 10px;}
}


.section
{
width: 100%;
height: 80vh;
padding: 30vh 0 50px 0;
text-align: center;
}


.content
{
background: #FFF;
background: rgba(255,255,255,.8);
padding: 40px 40px 20px 40px;
width: 40%;
margin: 0 auto 0 auto;
text-align: center;
}

#intro
{
background: url('img/intro.jpg');
background-size: cover;
background-attachment: fixed;
}

span.handsome
{
font-family: 'Handsome';
text-transform: none;
font-size: 45px;
line-height: 10px;
margin: 0 0 0 0;
}

h1,h2
{
font-family: 'GarageGothic';
text-transform: uppercase;
font-weight: normal;
font-size: 60px;
}

h2
{
margin: 0 0 20px 0;
}

h3
{
font-family: 'GarageGothic';
text-transform: uppercase;
font-weight: normal;
font-size: 40px;
margin: 0 0 20px 0;
}

.content p
{
font-family: 'OpenSans';
margin: 0 0 30px 0;
font-size: 18px;
}

.button
{
font-family: 'GarageGothic';
font-size: 30px;
background: #e65a50;
padding: 5px 30px 5px 30px;
cursor: pointer;
margin: 20px;
-webkit-box-shadow: 5px 5px 0px #bfbfbf;
-moz-box-shadow: 5px 5px 0px #bfbfbf;
box-shadow: 5px 5px 0px #bfbfbf;
text-align: center;
color: #000;
}

.button:hover
{
background: #ff665b;
}

.button:active
{
background: #e65a50;
}

.button-clicked
{
background: #d4edb5;
cursor: default;
}

.button-clicked:hover
{
background: #d4edb5;
}

.disabled
{
opacity: .5;
background: #CCC;
cursor: default;
}

.disabled:hover
{
background: #CCC;
}

.button a, .button a:visited
{
color: #000;
text-decoration: none;
}

span.steps
{
font-family: 'OpenSans';
font-size: 10px;
margin: 40px 0 0 0;
display: block;
color: #7e7e7e;
}

ul#sticky
{
position: fixed;
top: 25px;
left: 25px;
}

ul#sticky li
{
font-family: 'OpenSans';
padding: 10px;
color: #000;
background: #FFF;
background: rgba(255,255,255,0.8);
border-bottom: 1px solid #FFF;
border-right: 1px solid #FFF;
border-left: 1px solid #FFF;
font-size: 12px;
list-style: none;
}

ul#sticky li:first-child
{
border-top: 1px solid #FFF;
background: #FFF;
background: rgba(255,255,255, .8);
font-family: 'GarageGothic';
text-transform: uppercase;
font-size: 20px;
text-align: center;
}

img.checkmark
{
width: 10px;
height: 10px;
margin: 0 3px 0 0;
}

#vann-section
{
background: url('img/vann.jpg');
background-size: cover;
background-attachment: fixed;
}

#ifboligsjekk-section
{
background: url('img/ifboligsjekk.jpg');
background-size: cover;
background-attachment: fixed;
}

#boligsjekk-splash
{
width: 80px;
height: 80px;
display: block;
left: 25%;
margin: -50px 0 0 0;
position: absolute;

transition-duration: .2s, .2s;
transition-timing-function: linear, ease-in;

-ms-transition-duration: .2s, .2s;
-ms-transition-timing-function: linear, ease-in;

-webkit-transition-duration: .2s, .2s;
-webkit-transition-timing-function: linear, ease-in;

-o-transition-duration: .2s, .2s;
-o-transition-timing-function: linear, ease-in;

-moz-transition-duration: .2s, .2s;
-moz-transition-timing-function: linear, ease-in;

-webkit-perspective: 1000;
-webkit-backface-visibility: hidden;
}

#boligsjekk-splash:hover
{
transform: scale(1.1);
-ms-transform: scale(1.1);
-webkit-transform: scale(1.1);
-o-transform: scale(1.1);
-moz-transform: scale(1.1);
cursor: pointer;
}

#brannskader-section
{
background: url('img/brann.jpg');
background-size: cover;
background-attachment: fixed;
}

#handverker-section
{
background: url('img/håndverker.jpg');
background-size: cover;
background-attachment: fixed;
}

#sopp-section
{
background: url('img/sopp.jpg');
background-size: cover;
background-attachment: fixed;
}

#dyroginsekter-section
{
background: url('img/skadedyr.jpg');
background-size: cover;
background-attachment: fixed;
}

#leieinntekt-section
{
background: url('img/leieinntekt.jpg');
background-size: cover;
background-attachment: fixed;
}

#rettshjelp-section
{
background: url('img/rettshjelp.jpg');
background-size: cover;
background-attachment: fixed;
}

#tyveri-section
{
background: url('img/tyveri.jpg');
background-size: cover;
background-attachment: fixed;
}

#naturskade-section
{
background: url('img/naturskade.jpg');
background-size: cover;
background-attachment: fixed;
}

#resultat
{
width: 100%;
min-height: 80vh;
height: 100%;
padding: 30vh 0 50px 0;
text-align: center;
background: url('img/res.jpg');
background-size: cover;
background-attachment: fixed;
}

#resultat .content
{
padding: 40px;
}

#resultat p
{
line-height: 28px;
}

#resultat .button
{
display: inline-block;
font-size: 20px;
}

#button-ops-container
{
font-family: 'GarageGothic';
text-transform: uppercase;
font-size: 30px;
background: #e65a50;
padding: 5px 30px 5px 30px;
cursor: pointer;
margin: 20px;
-webkit-box-shadow: 5px 5px 0px #bfbfbf;
-moz-box-shadow: 5px 5px 0px #bfbfbf;
-o-box-shadow: 5px 5px 0px #bfbfbf;
-ms-box-shadow: 5px 5px 0px #bfbfbf;
box-shadow: 5px 5px 0px #bfbfbf;
text-align: center;
color: #000;
}

#button-ops-container:hover
{
background: #ff665b;
}

#button-ops-container:active
{
background: #e65a50;
}

#ops
{
color: #000;
text-decoration: none;
}

#ops:visited
{
color: #000;
}

最佳答案

马上,我会尝试删除任何 CSS animationtransformperspective,看看是否可以停止闪烁。如果不确切知道脚本完成了什么,以及元素是如何分层的,就很难说清楚。

关于html - 网页在 iOS 7 中崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28472893/

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