和视频js youtube播放列表播放器的字幕/翻译字幕

时间:2013-04-20 02:12:09

标签: html5 video.js

我编辑了一些代码,并进行了一些更改,以便让youtubeplaylist播放器运行视频js

我想知道如何为播放列表添加字幕或翻译字幕

示例在这里:

http://bestimage.x10.mx/Playlist_yt/YouTube_PlayList.html

<!DOCTYPE html>
<html>
<head>
     <title>YouTube Playlist Video Player</title>

 <link href="./css/video-js.css" rel="stylesheet">
 <link href="./css/video-js_playlist.css" rel="stylesheet" type="text/css">

 <script src="./js/video-js_youtube.js"></script>
 <script src="./js/video-js_playlist.js"></script>
     <script>_V_.options.flash.swf = "video-js.swf";</script>

</head>

<body>

<div text-align:center>
  <video id="vid1"
     class="video-js vjs-default-skin"
     controls
     preload="auto"
     width="854"
     height="480"
     data-setup='{"techOrder":["html5","flash","youtube"],"ytcontrols":false,
       "playlist":[
        {"thumb_url":"media/gates_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=fQ-ktGaWYlg",
              "type":"video/youtube",
              "media":"",
              "title":""},
            ]
          },
        {"thumb_url":"media/AndYouAndI_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=AYmeJlm7Gcg",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/CloseToTheEdge_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=Ne317y_eOYs",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/AllGoodPeople_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=bu1p2raTsbA",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/PerpetualChange_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=1GYl3rVhQMY",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/BabaORiley_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=hKUBTX9kKEo",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/WhoAreYou_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=zufuNr1GBYI",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/PinballWizard_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=aOUqRZkR8dE",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/MagicBus_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=ob9w9F12SZM",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          },
        {"thumb_url":"media/5_15_th.jpg",
           "poster_url":"",
           "sources":[
             {"src":"http://www.youtube.com/watch?v=9Qv6QTrWXN4",
              "type":"video/youtube",
              "media":"",
              "title":""},
           ]
          }
        ]

      }'>
   </video>
  </div>
 </body>
</html>

TIA

0 个答案:

没有答案