1
我已經嵌入div
是視口的全寬度內的VIMEO。該視頻完美運行了幾天,但現在播放按鈕(和所有其他按鈕)完全沒有響應。全寬的Vimeo嵌入無響應
我已經試過搞亂與周圍的z-index
,但不起作用。
<div class="full-screen-vid">
<iframe src="https://player.vimeo.com/video/192013765" width="100%" height="700" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
</div>
.full-screen-vid {
width: 100vw;
position: relative;
left: 50%;
right: 50%;
margin-left: -50vw;
margin-right: -50vw;
margin-top: 90px;
z-index: -1;
}
有一個奇怪的消息,我在我擡頭,並試圖修復控制檯中獲得,但我不認爲這是問題(或者整個的問題),因爲如果我刪除視頻從full-screen-vid
,它工作正常。
控制檯消息:
Refused to load the script'data:application/javascript;base64,KGZ1bmN0aW9xxxxIGZ1…xxxxxxxxxxxx='
because it violates the following Content Security Policy directive: "script-src 'self' 'unsafe-inline'
https://f.vimeocdn.com https://ssl.google-analytics.com https://js-agent.newrelic.com https://bam.nr-data.net https://f.vimeocdn.com".
你爲什麼要在div中加載iframe?你爲什麼不給iframe全屏幕vid的CSS? – junkfoodjunkie
不錯的建議,但我仍然有同樣的問題 – SamYoungNY
實際上 - 這樣做和chaning'z-index'確實工作,謝謝!如果你把它作爲答案,我會標記它是正確的。 – SamYoungNY