【发布时间】:2019-07-27 02:25:27
【问题描述】:
将我的项目放在主根目录的文件夹中,我创建了一个简单的 hello world 项目。加载到 chrome 中的 Html 文件效果很好,但是,在主项目文件夹或子文件夹中加载文件会给出 net::ERR_FILE_NOT_FOUND
我想在后台使用基本的叠加层和按钮自动播放视频(已经设置为可以在桌面上运行)。
尝试将文件位置移动到主文件夹并将目录重命名为没有空格。
还尝试使用 file:/// 而不是通过 chrome 中的文件资源管理器打开。
在 Pixel 2XL 上使用 Android v10
<body>
<div id="mainCont">
<spread class="header">Main Test</spread><br>
<button> <a href="ALTs/L1.html">Layout 1</a></button>
</div>
<div>
<video playsinline autoplay muted loop id="bgVideo">
<source src="Link/VerticalTest.mp4" type="video/mp4">
</video>
</div>
</body>
<style>
@font-face {
font-family: Lato;
src: url(/FontRef/ProximaNova-Bold.otf) format('opentype'),
url(/FontRef/ProximaNova-Light.otf) format('opentype'),
url(/FontRef/ProximaNova-Reg.otf) format('opentype'),
url(/FontRef/ProximaNova-It.otf) format('opentype'),
url(/FontRef/ProximaNova-Sbold.otf) format('opentype'),
}
body{
text-align: center;
font-family: ProximaNova-Reg, sans-serif;
}
#bgVideo {
z-index:-1;
position: fixed;
right: 0;
top: 0;
width: 100%;
}
#mainCont{
padding: 5em;
z-index:10000;
positoin: absolute;
top:50%;
transform: translateY(100%);
}
a{
color:white;
text-decoration: none;
}
button{
padding:10px;
margin:2em;
color: #494949 !important;
text-transform: uppercase;
text-decoration: none;
background: none;
border: 1px solid white !important;
display: inline-block;
transition: all 0.4s ease 0s
}
button:hover{
color: #ffffff !important;
background: #f6b93b;
border-color: #f6b93b !important;
transition: all 0.4s ease 0s;
}
.header{
font-family: ProximaNova-Sbold, sans-serif;
font-size: calc(2.87em - 1vw);
color:white;
font-weight:400;
text-transform:uppercase;
letter-spacing:.6em;
margin-top:calc(6em - 1vw);
}
在我的 Android 设备上使用 chrome 中的远程调试器,net::ERR_FILE_NOT_FOUND 是我收到的视频文件的唯一问题。由于某种原因正在应用的字体没有这样的错误?
【问题讨论】:
-
为 webview 启用 javascript 然后重试
标签: android html google-chrome android-webview