This macro isn't bundled with any XWiki product by default.
Macro contributed by Thomas Eveilleau.
This macro cannot currently be downloaded separately.

IframeNavigation Macro

Allow you to add an iframe in the content of a page with links to change the website displayed in the iframe (its an Iframe+ Macro)

Usage

#iframelink("URL" "Iframe Name" "Text displayed")
#iframelink("URL" "Iframe Name" "Text displayed")

#iframebox("Iframe Name" "Width" "Height")

Parameters definition

For the #iframelink Macro

NameOptionalAllowed valuesDefault valueDescription
URLnostringnoneURL of the website you want to display in your iframe
Iframe NameyesstringiframeName of the iframe you want to target
Text DisplayedyesstringlinkText displayed for the link

For the #iframebox Macro

NameOptionalAllowed valuesDefault valueDescription
Iframe NameyesstringiframeName of the Iframe
Widthyesint +px or percentage +%100%Width of the iframe
Heightyesint +px500pxHeight of the iframe

Example

* #iframelink("http://www.google.fr" "" "Google")
* #iframelink("http://www.yahoo.fr" "" "Yahoo")

----

#iframebox("" "100%" "500")

Result

iframeplusresult.png

Installation

This a Velocity macro. Since it's not bundled by default you'll have to copy/paste the following code to use it:

#macro(iframelink $url $target $text)
#if($target=="")
#set($target="iframe")
#end
#if($text=="")
#set($text="link")
#end
<a href="${url}" title="iframelink" target="${target}">${text}</a>
#end

#macro(iframebox $name $width $height) #if($name=="") #set($name = "iframe") #end #if($width=="") #set($width="100%") #end #if($height=="") #set($height="500px") #end <iframe name="${name}" width="${width}" height="${height}"></iframe> #end

Version 4.1 last modified by VincentMassol on 19/06/2008 at 22:05

Comments 0

No comments for this document

Attachments 1

Image
iframeplusresult.png 1.1
PostedBy: ThomasEveilleau on 12/05/2008 (106kb )

Creator: ThomasEveilleau on 2008/05/12 11:01
This wiki is licensed under a Creative Commons license
1.4.1.10194