NOTE: Allowing the <iframe> HTML element has serious security implications.  Make sure you are fully aware of them before you enable this function.

Vendor
MindTouch
Type Script
Categories Misc
Requires MindTouch Core 1.8.3 or later
Status Stable
License Free/Open Source
Manifest http://scripts.mindtouch.com/iframe.xml

 

Install Script
To add  this script to your site, enter the address of your MindTouch installation (ex: http://www.mindtouch.com) and click the Add Script button.  This will open your control panel and prepopulate the necessary values.  You will still need to manually add configuration settings if required.  Note that no changes are made to your site until you confirm the action in your control panel.
Your site address:     


Table of Contents

Description

This extension contains a function for embedding <iframe> elements.

See also How to add a script, Using the Extension Dialog, Learn about DekiScript, Extensions Directory.


Functions

iframe(uri : uri, width : num, height : num, scrolling : bool, frameborder : num) : xml

Embed an iframe element.

Parameters:

NameTypeDescription
uriuriThe iframe URI.
widthnum(optional) The iframe width. (default: 425)
heightnum(optional) The iframe height. (default: 350)
scrollingbool(optional) Allow scrollbars inside the iframe. (default: no)
framebordernum(optional) Frame border thickness on the iframe. (default: 0)


Script Source

<extension>
  <title>MindTouch iFrame Extension</title>
  <copyright>Copyright (c) 2006-2009 MindTouch Inc.</copyright>
  <uri.help>http://developer.mindtouch.com/App_Catalog/iFrame</uri.help>
  <label>iFrame</label>
  <description>This extension contains a function for embedding &lt;iframe&gt; elements.</description>

  <function>
    <name>iframe</name>
    <description>Embed an iframe element.</description>
    <param name="uri" type="uri">The iframe URI.</param>
    <param name="width" type="num" optional="true">The iframe width. (default: 425)</param>
    <param name="height" type="num" optional="true">The iframe height. (default: 350)</param>
    <param name="scrolling" type="bool" optional="true">Allow scrollbars inside the iframe. (default: no)</param>
    <param name="frameborder" type="num" optional="true">Frame border thickness on the iframe. (default: 0)</param>
    <return>
      <html xmlns:eval="http://mindtouch.com/2007/dekiscript">
        <body>
          <iframe eval:src="args.uri" eval:width="web.size(args.width ?? 425)" eval:height="web.size(args.height ?? 350)" marginwidth="0" marginheight="0" hspace="0" vspace="0" eval:frameborder="args.frameborder ?? 0" eval:scrolling="args.scrolling ? 'yes' : 'no'" />
        </body>
      </html>
    </return>
  </function>
</extension>

Tag page (Edit tags)
Viewing 5 of 5 comments: view all
When I try to turn on the scrollbars within the iFrame using the "scrolling" option, I get the following error:

/p[2]/span, function 'local://d23c587d48b342eba621a61df1e90bfc/deki/services/ourwiki.company.com/16/iframe' failed with response:
could not convert parameter 'scrolling' (index 4) to bool

Any ideas why using the option: scrolling: "yes" would cause this?

Eamon.
Posted 17:40, 27 Jan 2009
To activate scrolling, use true instead of yes for that argument.
Posted 19:20, 9 Mar 2009
sample?
Posted 19:04, 8 Apr 2009
Can somebody PLEASE be more helpful with this example, WHY are all these documentation so FRIGGIN obscure??
Sense any frustration yet???
Posted 22:08, 4 Jun 2009
This worked for me:

{{ iframe{uri: "http://news.bbc.co.uk", scrolling: "TRUE"} }}
Posted 08:02, 23 Oct 2009
Viewing 5 of 5 comments: view all
You must login to post a comment.