====== iframe plugin ====== ---- plugin ---- description: Allows external URLs to be loaded into an iframe in your DokuWiki page. author : Christopher Smith email : chris@jalakai.co.uk type : syntax lastupdate : 2008-10-31 compatible : 2006-11-06 and above depends : conflicts : similar : tags : embed, !broken ---- This plugin allows you to embed other web sites in a DokuWiki page using an iframe. Additional info might be available at the [[http://wiki.jalakai.co.uk/dokuwiki/doku.php/tutorials/iframe|developer's website]]. ===== Download and Installation ===== Download and install the plugin using the [[plugin:plugin|Plugin Manager]] using the one of the following URLs. Refer to [[:Plugins]] on how to install plugins manually. * {{http://dokuwiki.jalakai.co.uk/plugin-iframe.zip}} zip format (4k) * {{http://dokuwiki.jalakai.co.uk/plugin-iframe.tar.gz}} tar.gz format (3k) The plugin is also available via [[devel:darcs]] from this URL: * [[http://wiki.jalakai.co.uk/repo/dokuwiki/plugins/iframe]] ==== Revision History ==== * 2008-10-13 * more relaxed syntax * new parameters * 2006-12-17 * update for stricter type/error checking in php 5 (thanks Ilya) * add support for controlling settings through config plugin * 2006-05-01 --- (darcs version only, others to follow) settings moved to use [[devel:common plugin functions]] making them editable via the [[plugin:config|configuration manager]] in the admin menu. * 2005-10-17 --- Released. ==== Manual Installation ==== To install the plugin manually, download the source to your plugin folder, ''lib/plugins'' and extract its contents. That will create a new plugin folder, ''lib/plugins/iframe'', and install the plugin. The folder will contain: conf/default.php default settings conf/metadata.php settings information for the config plugin lang/xx/lang.php language strings for config plugin syntax.php plugin script ===== Syntax and Usage ===== Simple: {{url>http://www.example.com/somepage.html}} Complete Syntax: {{url>someurl width,height noscroll noborder alignment|alternate-text}} That is an URL to embed, followed by several optional parameters. The following parameters are recognized: * //width// and //height// are optional. When only one value is given it is assumed to be the height. Otherwise the first value is width and the second value is height. You can give the values in ''px'', ''em'', ''pt'' or ''%''. When no unit is given ''px'' is is NOT assumed (you have to give the value). Defaults values are: width - 98%, height - 400px. * ''noscroll'' will disable the scrollbars of the iframe * ''noborder'' will disable the frame border, note that your CSS might still add borders or may disable them without using this setting * Optionally an //alignment// can be given as ''left'' or ''right'' to have the iframe floating to the left or right. Should be used with a width. * An //alternate text// is optional. If not specified an empty string will be used. See the plugin in action [[http://wiki.jalakai.co.uk/dokuwiki/doku.php/test/iframe|here]]. ===== Configuration ===== The plugin has one configuration setting, which can be set via the admin/configuration settings page. * $js_ok --- default value - ''false'', set to ''true'' to enable JavaScript URLs. :!: This should never be enabled in public wikis as it opens a XSS security hole. ===== Acknowledgments ===== The plugin was created in response to an idea mentioned by [[styno@hotmail.com|Styno]]. This plugin was used as a basis for [[plugin:google_cal]] by [[Kite@puzzlers.org|Kite]]