Fórum

Unable to play movie using AlloyUI on Liferay 6.2 GA2

Muhammad Umer Zubair, modificado 8 Anos atrás.

Unable to play movie using AlloyUI on Liferay 6.2 GA2

New Member Postagens: 18 Data de Entrada: 01/01/14 Postagens Recentes
Hi,

I am using Liferay 6.2 GA2, and trying to play movie using this code, but no luck. Can anybody guide me in this regard.


<div id="myVideo">&nbsp;</div>
<script>
YUI().use(
  'aui-video',
  function(Y) {
    new Y.Video(
      {
        boundingBox: '#myVideo',
        height: 600,
        url:'/documents/10181/90571/Movie.mp4',
        width: 800
      }
    ).render();
  }
);
</script>

Any help will be highly appreciated.
thumbnail
Juan Gonzalez, modificado 8 Anos atrás.

RE: Unable to play movie using AlloyUI on Liferay 6.2 GA2 (Resposta)

Liferay Legend Postagens: 3089 Data de Entrada: 28/10/08 Postagens Recentes
What do you mean by "no luck"? Any error in javascript console?

Probably you should use AUI instead of YUI.

You should check if that MP4 URL actually works.

To get rid of these and other errors I would recommend you to use Liferay's OOTB video preview feature (Xuggler), and then play those videos in document library or in web content (new video buttons will display in CKEditor when that feature is enabled).
Muhammad Umer Zubair, modificado 8 Anos atrás.

RE: Unable to play movie using AlloyUI on Liferay 6.2 GA2

New Member Postagens: 18 Data de Entrada: 01/01/14 Postagens Recentes
Hi,

Thanks for the quick response. Acutally no luck means, that neither movie player was visible nor the movie. As advised, I have double checked the followings:

1. Movie URL is correct.
2. Tried with AUI, but unable to play.
3. Tried all formats, like mp4, wmv, swf, but unable to play

However, as per your advise, i enabled Xuggler, and found that wmv, mp4 files are being played in documents and media section. Then i used "insert movie" button in web content section, and it played like charm. emoticon

So, ultimately, movie played with the default provided player/configuration. Thanks for the advise.
thumbnail
Juan Gonzalez, modificado 8 Anos atrás.

RE: Unable to play movie using AlloyUI on Liferay 6.2 GA2

Liferay Legend Postagens: 3089 Data de Entrada: 28/10/08 Postagens Recentes
Hi Muhammad,

glad you got it working emoticon.

Yes, video playing in browsers isn't usually a quick-win, there are some conditions that should be met (video codecs, partial HTTP request/response support, HTML5 video browser support, etc). Using Liferay video preview feature avoids this kind of problems in future.

Thanks for your feedback.