Forums | Mahara Community

Open Discussion /
windows live blocktype


Syed Anwar's profile picture
Posts: 21

24 May 2012, 22:10

Dear All,

Why i cannot view Windows Live at eportfolio page after i embed code from my skydrive? I've done set share to everyone/public.

Example embed code:

<iframe src="https://skydrive.live.com/embed?cid=E490BC7E8BCD4668&resid=E490BC7E8BCD4668%21177&authkey=AJoCQdlhxrI_FcM" width="98" height="120" frameborder="0" scrolling="no"></iframe>

Can any one help me?or any problem at my windows live block?

Regards

Kristina Hoeppner's profile picture
Posts: 4867

25 May 2012, 4:04

Hello Syed,

You are trying to embed an iFrame which in general is stripped out of a text box by HTML Purifier for security reasons.

If you are using Mahara 1.5, you can add this iFrame source, and others you deem as safe, in your code. You can find more information about that in the user manual.

If you work with an earlier version of Mahara, you might be able to use Gregor's Windows Live block type plugin. However, the instructions on the page do not mention SkyDrive explicitely. Thus, it could be that its iFrames are not supported there.

You can also write a custom filter, like it exists for YouTube and others, that specifically allows that iFrame source. That can be done for any version of Mahara.

Cheers

Kristina

Syed Anwar's profile picture
Posts: 21

27 May 2012, 22:38

Thank you Kristina for reply,

But, i try many times to add iFrame source code my skydrive in .../lib/web.php but still cannot view. MayB my code incorrect.

Example: $safeiframesources = array('www\.youtube\.com/embed/',
                               'player\.vimeo\.com/video/',
                               'www\.slideshare\.net/slideshow/embed_code/',
                               '(www|edu)\.glogster\.com/glog(/|\.php)',
                               'wikieducator\.org/index\.php',
                               'skydrive\.live\.com/embed',
                               );

This is correct?Sorry because i'm beginner in programming...=)) I'm now using mahara 1.5 in testing server.

Regards

-Syed-

Kristina Hoeppner's profile picture
Posts: 4867

28 May 2012, 5:52

Hello Syed,

The code looks fine to me and I tried it with the Skydrive URLs that I had for testing purposes and either an icon or a preview image shows up in the text box. Did you try putting it into the "External content" block or into the "Text box"? It doesn't show up in "External content" for me but in the text box.

It might only be possible to use the iframe in the text box for the time being until there is the admin interface which is in 1.6. That will also get you around using regex notification and escaping as you had to do in the code. Smile

Cheers

Kristina

A post by Account deleted was deleted

5 results