Media Player with external videos


Joseph Caristena

Hi,
Is it possible to use the Media Player with external videos on a web site ?

I am using the following script and it works properly.

NewArray "[VideoSources]"
ArrayPush "[VideoSources]" "app/files/a.mp4"
ArrayPush "[VideoSources]" "app/files/b.mp4"
ArrayPush "[VideoSources]" "app/files/c.mp4"

SetVar "[CurrentVideoIndex]" "0" "Number"
ArrayLength "[VideoSources]" "[TotalVideoSources]"

ArrayGetItem "[VideoSources]" "[CurrentVideoIndex]" "[CurrentVideoPath]"
MediaSetSource "MediaPlayer1" "" "[CurrentVideoPath]" "" ""

But can I use something like this ?

NewArray "[VideoSources]"
ArrayPush "[VideoSources]" "www.egovmetrics.com/AppMobilePlatform/Video/a.mp4"
ArrayPush "[VideoSources]" "www.egovmetrics.com/AppMobilePlatform/Video/b.mp4"
ArrayPush "[VideoSources]" "www.egovmetrics.com/AppMobilePlatform/Video/c.mp4"

SetVar "[CurrentVideoIndex]" "0" "Number"
ArrayLength "[VideoSources]" "[TotalVideoSources]"

ArrayGetItem "[VideoSources]" "[CurrentVideoIndex]" "[CurrentVideoPath]"
MediaSetSource "MediaPlayer1" "" "[CurrentVideoPath]" "" ""

It can be useful to handle the media content on a web site.

Thanks
Best
Joseph Caristena


DecSoft

Hello,

There is no problem to use absolute URLs, in fact this is the recommended way, since we can't reproduce local files in platforms like Android. If you have problems using absolute URLs, try to start the URLs by the "http://www." instead "www.".



Joseph Caristena

Hi,
I am using absolute URLs now.
But something strange is happening.
I hear the audio, but I do not see the video.
Why ?

Thanks
Best
Joseph Caristena


DecSoft

Hello,

Probably a "codec" related problem Joseph... for that reason we need to provide as much sources as possible: to let the browser to choose the more appropiate/suitable source to be reproduced. Honestly I don't think this is a problem of AB nor the media player control, but the video/browser itself... are you tried the video in various browsers? Are the results the same?



Joseph Caristena

Hi,
You are right;)
Now it is working.

Thanks
Joseph Caristena

Todo el mundo puede leer el foro de soporte de DecSoft para aprender del mismo, sin embargo, sólo los clientes de DecSoft pueden abrir nuevos hilos. Compre una o más licencias de productos de DecSoft y obtendrá este y otros beneficios.

Este sitio utiliza "cookies" útiles para almacenar sus preferencias.

Bien. Ocultar esta nota. Obtener más información.