2013-06-24 37 views
2

我剛開始jwplayer工作,我有幾個問題:剛開始jwplayer工作,我有幾個問題

  1. 如何連接/顯示標題旁邊的縮略圖(類似YouTube )?我必須自己創建縮略圖還是jwplayer會爲我做這個?

  2. 播放列表部分看起來很枯燥,它只顯示標題。如何顯示視頻的其他信息?即時間,作者/上傳者等。

請指向我的文檔,如果有一個,到目前爲止我還沒有找到它。

我當前的代碼:

<script type="text/javascript"> 
    jwplayer("myElement").setup({ 
     playlist: [{ 
      file: "/common/assets/sample_iPod.m4v", 
      title: "Sample Video 1" 
     },{ 
      file: "/common/assets/Wildlife_512kb.mp4", 
      title: "Animals being CUTE!!!" 
     },{ 
      file: "https://s3.amazonaws.com/asteroid.static.www.otcmarkets.com/videos_presentations/OTCM/Wildlife_512kb.mp4", 
      title: "video from S3" 
     },{ 
      file: "https://s3.amazonaws.com/asteroid.static.www.otcmarkets.com/videos_presentations/OTCM/sample_iPod.m4v", 
      title: "ipod help from S3" 
     }], 
     width: 770, 
     height: 360, 
     listbar: { 
      position: 'right', 
      size: 240 
     } 
    }); 
</script> 

enter image description here

回答

1

要做到這些,你會添加圖像,以及描述,每個播放列表條目。

參考 - http://www.longtailvideo.com/support/jw-player/29249/playlist-sidebar-component

代碼使用:

<div id="myElement"></div> 

<script> 
    jwplayer("myElement").setup({ 
     playlist: [{ 
     file: "/uploads/sintel.mp4", 
     image: "/uploads/sintel.jpg", 
     title: "Sintel Trailer", 
     description: "Sintel is a fantasy CGI movie from the Blender Open Movie Project." 
     },{ 
     file: "/uploads/tears.mp4", 
     image: "/uploads/tears.jpg", 
     title: "Tears of Steel Trailer", 
     description: "A complete open pipeline was used to produce this visual effect film." 
     },{ 
     file: "/uploads/bunny.mp4", 
     image: "/uploads/bunny.jpg", 
     title: "Big Buck Bunny Trailer", 
     description: "This animated film is made using free and open source software." 
     },{ 
     file: "/uploads/elephants.mp4", 
     image: "/uploads/elephants.jpg", 
     title: "Elephants Dream Trailer", 
     description: "This is the worlds first open movie, made entirely with Blender." 
     }], 
     width: 700, 
     height: 240, 
     listbar: { 
     position: "right", 
     size: 280 
     } 
    }); 
</script> 
+0

hmmmm,所以沒有辦法,我可以顯示該那麼上傳的日期? – iCodeLikeImDrunk

+0

例如,除非您只是將日期放入說明中。 – emaxsaun

+0

我看到了,還有更多的問題,上傳截圖,注意播放列表的右側,說明幾乎觸及邊緣,無論如何,我可以將說明向左移動一點,以便描述不會如此接近邊緣?最後,由於我不打算自己製作縮略圖,是否有可能在播放列表沒有標題/描述旁邊的大X(盒子),以便播放列表只顯示標題/描述/等? – iCodeLikeImDrunk