soiz1 commited on
Commit
71ac320
·
1 Parent(s): 1d6ef1a

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +6 -3
index.html CHANGED
@@ -606,10 +606,13 @@
606
  document.addEventListener('DOMContentLoaded', function() {
607
  const urlParams = new URLSearchParams(window.location.search);
608
  const isTMode = urlParams.has('mode') && urlParams.get('mode') === 't';
609
- const video = document.getElementById('video');
610
 
611
- if (isTMode) {
612
- video.querySelector('source').src = '/t/v.mp4';
 
 
 
613
  }
614
  });
615
  </script>
 
606
  document.addEventListener('DOMContentLoaded', function() {
607
  const urlParams = new URLSearchParams(window.location.search);
608
  const isTMode = urlParams.has('mode') && urlParams.get('mode') === 't';
609
+ const videoSource = document.querySelector('#video source'); // source要素を取得
610
 
611
+ if (isTMode && videoSource) {
612
+ videoSource.src = '/t/v.mp4';
613
+ // 動画を再読み込み
614
+ const video = document.getElementById('video');
615
+ video.load();
616
  }
617
  });
618
  </script>