浏览代码

test video

huaisianhuang 3 年之前
父节点
当前提交
57b4ed4d33
共有 2 个文件被更改,包括 2 次插入8 次删除
  1. 2 1
      index.html
  2. 0 7
      js/index.js

+ 2 - 1
index.html

@@ -274,7 +274,8 @@
       <div class="modal-dialog modal-dialog-centered">
         <div class="modal-content">
           <div class="modal-body text-center">
-            <iframe width="340" height="230" allow="autoplay;"></iframe>
+            <iframe width="345" height="190" frameborder="0" allowfullscreen="1" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" title="YouTube video player" 
+              id="widget2"></iframe>
           </div>
         </div>
       </div>

+ 0 - 7
js/index.js

@@ -282,13 +282,6 @@ $(".sec-01__slider").slick({
     $('.navbar-back-fav').click(function(){
       $(".sec-favor").css('display', 'none');
     })
-    
-    $('#videoModal').on('shown.bs.modal', function () {
-        $('#videoModal iframe').attr('src', 'https://www.youtube.com/embed/G7baBXAhC_I?controls=0&autoplay=1&amp;enablejsapi=1&amp;origin=https%3A%2F%2Fm.hhh.com.tw&amp;widgetid=1');
-      })
-      $('#videoModal').on('hidden.bs.modal', function () {
-        $('#videoModal iframe').removeAttr('src');
-      });
 
       $('.btn-gotop').click(function () {
         $('html, body').animate({