Forums | Mahara Community

Support /
Read external videos


19 June 2014, 2:28

Hello,

I created a html file or I insert the embed code into a text box, the video does not start.
An example link http://savoir.neopodia.com/20090914-histoire-renaissance-jean-calvin-calvinisme-modernite-heritage?t=11#

and code :

<div><object width="480" height="306" data="http://savoir.neopodia.com/fichierpodcast/244/mp4" type="application/x-shockwave-flash" class="playerpreview">
<param name="wmode" value="transparent"/>
<param value="http://savoir.neopodia.com/fichierpodcast/244/mp4" name="movie"/>
<param name="allowNetworking" value="all" />
<param name="allowScriptAccess" value="always" >
<param value="http://savoir.neopodia.com/themes/neopodia/medias/player_flv_blog_as3.swf" name="movie"/>
<param value="true" name="allowFullScreen"/>
<param value="flv=http://media.neopodia.com/savoir/podcasts/public/download/090707_calvin-3_small.mp4&startimage=http://savoir.neopodia.com//sites/default/files/contenu/photos-illustrations/histoire/renaissance-empire/formatgeneral409260/gravure-calvin2_large.jpg&width=480&height=306&loop=1&margin=5&showstop=1&showvolume=1&showtime=1&showplayer=always&showfullscreen=1&playercolor=7a7a7a&playeralpha=50&loadingcolor=EE972E&buttonovercolor=EE972E&sliderovercolor=EE972E&showiconplay=1&iconplaycolor=ffffff&iconplaybgcolor=000000&iconplaybgalpha=50&videobgcolor=000000&showtitleandstartimage=1&autoplay=0&onclick=http://savoir.neopodia.com/20090914-histoire-renaissance-jean-calvin-calvinisme-modernite-heritage?t=11&onclicktarget=_blank&statPath=http://savoir.neopodia.com/lienFichierPodcast/blog/244/video/5/SD" name="FlashVars"/></object>
</div>

It works with Wordpress but not with Mahara

Many thanks for your help

AlainG

 

19 June 2014, 4:21

Bonjour Alain

L'explication est peut la suivante :

Mahara processes all HTML code through a script called HTML-purified which is here to prevent harmful code to be run.

I presume that <object> is trimmed away by HTML-purifier. You could avoid that by authorising an iframe source and then using <Iframe> Instead of <object>

You can also write a filter in php to change the rules used by HTML-purifier to clean the code.

Bon travail sur Mahara.

D Jan
Kristina Hoeppner's profile picture
Posts: 4729

22 June 2014, 13:29

Hello Alain,

HTML Purifier is not stripping out your entire code. Oftentimes, <embed> and <object> embed codes work fine as no special filter is needed. However, in the case of your <object> code, parts of it are stripped out because they could be causing a security problem. As dajan wrote, a filter or rule for HTML Purifier would be necessary to let these videos through.

Before you go through this, you could check with Neopodia if they also have an iframe option or are planning to have one.

Cheers

Kristina

 

3 results