Iframe Macro
This is a Velocity macro, which isn't bundled with any XWiki product by default.
Macro contributed by Thomas Eveilleau.
This macro cannot currently be downloaded separately.
Macro contributed by Thomas Eveilleau.
This macro cannot currently be downloaded separately.
Iframe Macro
Allow you to add an iframe in the content of a pageUsage
#iframe("url" "name" "width" "height")Parameters definition
| Name | Optional | Allowed values | Default value | Description |
|---|---|---|---|---|
| URL | no | string | none | URL of the website you want to display in your iframe |
| Name | yes | string | iframe | Name of the iframe |
| Width | yes | int +px or percentage +% | 100% | Width of the iframe |
| Height | yes | int +px | 500px | Height of the iframe |
Example
#iframe("http://www.google.fr" "google" "" "")Result
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(iframe $url $name $width $height)
#if($name=="")
#set($name = "iframe")
#end
#if($width=="")
#set($width="100%")
#end
#if($height=="")
#set($height="500px")
#end
<iframe src="${url}" name="${name}" width="${width}" height="${height}"></iframe>
#end