Overview:
The {iframe} macro allows you to display a web-page within a web-page
Parameters:
Add the macro to your page as follows:
{iframe:src=http://www.adaptavist.com}
text to show when browser does not support iframes
{iframe}
| At least the src parameter must be specified You must specify at least the src parameter for this macro to work. |
| Parameter | Required | Default | Notes |
|---|---|---|---|
| class | The class to associate with the tag. Multiple classes can be specified by separating them with spaces. | ||
| style | An optional inline style sheet to apply to the tag. | ||
| title | Optional extra information about the tag | ||
| id | The html ID of the tag | ||
| align | The alignment of the iframe (left/right/top/middle/bottom) | ||
| frameborder | Whether to display a border (0/1) | ||
| height | The iframe height in px/% | ||
| longdesc | A url to a page which contains a long description of the content within the iframe | ||
| marginheight | The size of the top/bottom margins of the iframe | ||
| marginwidth | The size of the left/right margins of the iframe | ||
| name | The name of the iframe | ||
| scrolling | Whether to show scrollbars or not (yes/no/auto) | ||
| src | The url to be displayed within the iframe | ||
| width | The width of the iframe in px/% |









Comments (24)
Jul 18, 2009
David Chapman says:
Is there any way to set the allowTransparency attribute? http://msdn.microsoft....Is there any way to set the allowTransparency attribute?
http://msdn.microsoft.com/en-us/library/ms533072(VS.85).aspx
I know this is non standard but I can't use this macro because in IE, it needs this set for it to work properly.
Jul 19, 2009
Alain Moran says:
We have no plans to add non-standard properties to any of the HTML macros contai...We have no plans to add non-standard properties to any of the HTML macros contained by the content formatting plugin - you should create a user-macro instead.
Aug 05, 2009
Theo Schachter says:
I have a concept design I'm finding difficult to realize. In my wiki page, I've...I have a concept design I'm finding difficult to realize.
In my wiki page, I've assigned a number of small jpgs as links to other children pages. I want the Navigation icons I've created to always be on the screen, but inorder to do that, I've had to copy and past the markup code onto every child page. Plus, there are a lot of attachments. The whole thing is quite combersome. The icons represent the majority of the coding, so what I hope to do is embed several iframes into the "mother" page, and use the icons to trigger text content appearing in the iframes.
How can I use these icons to trigger the content in the iframes?
Aug 05, 2009
Alain Moran says:
Wow, now that's what I call doing things the hard way! The answer to your quest...Wow, now that's what I call doing things the hard way!
The answer to your question is to use the target parameter in the anchors and point them at the frames you are using ... however what you are describing sounds very much like it would be much easier to achieve using a theme plugin.
Have you thought about using the Theme Builder Plugin, it's free and it's a chuff of a lot easier to maintain than the situation you have described above!
Aug 27, 2009
Theo Schachter says:
Ok, here's another tough one. RE: iframe, I want to attach an html or pdf file ...Ok, here's another tough one.
RE: iframe, I want to attach an html or pdf file to my wiki site containing a series of illustrative charts. I want to use the iframe macro to display the attachment. So far no problem, but, then I want to place anchor macros in the wiki page that call targets in the iframe so that the iframe scrolls to the desired image in the attached html or pdf. Is there a way to do this? Also, I've noticed that html files require supporting files to display graphics, which is a problem I have not yet been able to work around. Is pdf then better for my purposes, and if so, can the iframe display the pdf. if not, what is the solution to the html graphic display issue?
To complicate matters further, my wiki is a corparate site, so I'm limited to the themes set by the administrator and cannot use the Theme Builder Plugin.
What what I'm suggesting simply is not possible, then do ou have any suggestions for a work around to create a similiar effect?
Looking forwrd to your reply.
Jan 05, 2010
Guillermo Chutrau says:
I am using iframe with URL's that point to PDF's in SharePoint. Works excellent....I am using iframe with URL's that point to PDF's in SharePoint. Works excellent.
I try to do the same thing with URL's that point to PDF's that are attachments in Confluence, copying the URL's I get from the attachments page. But instead of appearing in the iframe, I get a prompt to open, save, or cancel. If I select open, the file opens in a new window, rather than in the iframe.
Why? How can I fix that?
Thank you
Jan 05, 2010
Alain Moran says:
Confluence is probably adding http headers telling the browser that the file sho...Confluence is probably adding http headers telling the browser that the file should be downloaded rather than displayed - IMO this is the correct course of action since opening pdf files in the browser causes it to grind to a halt while the pdf engine renders the content.
Given that you actively want to open the pdf in the browser, I would be looking at using an object tag rather than an iframe.
Shamelessly ripped from the first link on google: http://joliclic.free.fr/html/object-tag/en/
Jan 06, 2010
Guillermo Chutrau says:
Thank you so much. That piece of code works very well in Confluence! Do you kno...Thank you so much. That piece of code works very well in Confluence!
Do you know if I can use it to display excel, word , and powerpoint files too? How should I modify it , other than changing the filename and path?
Cheers, Guillermo
Jan 06, 2010
Alain Moran says:
You would be better off using the excel macro, which appears to have changed in ...You would be better off using the excel macro, which appears to have changed in the latest release to become viewfile which even has a viewpdf mode
http://confluence.atlassian.com/display/DOC/View+File+Macro
Jan 07, 2010
Theo Schachter says:
Hi, I'm using the iframe to display some flash content. Works beautifully, but ...Hi,
I'm using the iframe to display some flash content. Works beautifully, but I cant loose the vertical scroll bar. I've used the following code:
Should be "scrolling=no" right?
You cant actually scroll with the bar, but it's still there. What am I doing wrong?
Would you have any ideas.
Jan 12, 2010
Theo Schachter says:
Regarding the above: please... what am I doing wrong? The scrolling issue. It's ...Regarding the above: please... what am I doing wrong? The scrolling issue. It's driving me crazy. Part of the issue might be that I'm usiung the iframe to call up an html file that calls a flash object. Would that contribute to the problem?
Feb 19, 2010
kicha says:
Currently I have three confluence spaces to hold project information and three j...Currently I have three confluence spaces to hold project information and three jira projects which holds the issues related to these projects. I created a left navigation theme with menus and applied the theme to three spaces.
I have created a page in each of the three spaces with the page content as
{iframe:src=http://localhost:8090/secure/VersionBoard.jspa?selectedProjectId=10000}{iframe:src=http://localhost:8090/secure/VersionBoard.jspa?selectedProjectId=10010}{iframe:src=http://localhost:8090/secure/VersionBoard.jspa?selectedProjectId=10020}so when I click on the menu of space 1 it takes me to a page which holds the project info for Project 1.
similarly for second and third space. In the above link only the projectid changes but the rest of the url remains same and also I have to create 1 page in each space to display the result. So If the number of projects increases, the number of pages too gets increased. Instead, I want to have only one page with iframe content as
{iframe:src=http://localhost:8090/secure/VersionBoard.jspa?selectedProjectId= }and pass the project key as per the confluence space from which the menu was clicked.
Is there any way to map confluence spaces to jira projects or can variables be declared in Confluence to hold jira projects as values.
Any suggestions?
Apr 14, 2010
Hor Pui Yin says:
Hi Hope I can some one can help me on the below questions. Does iframe macro...Hi
Hope I can some one can help me on the below questions.
Does iframe macro can work in IE7?
Could we edit google document that in iframe macro using Firefox browser?
Thanks.
Sep 24, 2010
Rian Murphy says:
Is there any way for this macro to supply a username and password for a URL that...Is there any way for this macro to supply a username and password for a URL that uses https?
Thanks, R.M.
Sep 24, 2010
Alain Moran says:
That would depend entirely on the system that you are communicating over https w...That would depend entirely on the system that you are communicating over https with (https does not include a username & password layer, that's usually implemented by the app that you are talking to)
Feb 17, 2011
Rian Murphy says:
We are having a problem involving the iframe macro: In the past couple of days ...We are having a problem involving the iframe macro:
In the past couple of days our Confluence installation has slowed down radically or stopped altogether. The logs for catalina from the times of these incidents show that one page is being hit hundreds and thousands of times – a page containing an iframe macro. The page displays some real-time-updated bar charts generated by a qa tool we run within our network. It's as if the page were being hit hundreds or thousands of times, which is unlikely and probably impossible.
Is it possible that the macro might be doing something flaky? It seems unlikely too, but I thought I'd check.
Thanks, R.M.
Feb 17, 2011
Alain Moran says:
More likely one (or more) of your users is refreshing the page repeatedly (possi...More likely one (or more) of your users is refreshing the page repeatedly (possibly via an automated tool which informs the user when a page has updated?).
The iframe macro, as with all the other "HTML Tag macros" just outputs an html tag ... it does nothing clever whatsoever.
Feb 17, 2011
Rian Murphy says:
I thought so. Thanks for the quick reply. R.M.I thought so. Thanks for the quick reply. R.M.
Jun 01, 2011
Markus Faleij says:
Hi! I want to display a website in Confluence but can't seem to loose the b...Hi!
I want to display a website in Confluence but can't seem to loose the borders. I have tried:
iframe:src=http://www.aaro.se/nyheterwiki.asp|frameborder=0|width=30%|height=400
But the borders is still there, any suggestion why it don't work?
I have Confluence version: 3.4.2,
/Markus
Jun 01, 2011
Alain Moran says:
I assume you mean the scrollbars, eg: {iframe:src=http://www.adaptavist.com|fra...I assume you mean the scrollbars, eg:
{iframe:src=http://www.adaptavist.com|frameborder=0|width=100|height=100}
without scrollbars:
{iframe:src=http://www.adaptavist.com|frameborder=0|width=100|height=100|scrolling=no}
Jun 01, 2011
Markus Faleij says:
Thanks for the quick reply /MarkusThanks for the quick reply
/Markus
Jun 01, 2011
Markus Faleij says:
Hi! I have one more question. Is there a way to make all the links inside the i...Hi!
I have one more question. Is there a way to make all the links inside the iframe open in another window outside the iframe.
/Markus
Jun 01, 2011
Alain Moran says:
Not without changing the target= parameter on all the links in the page that is ...Not without changing the target= parameter on all the links in the page that is embedded in the iframe.
If you have control over the target page then you should be able to do this using javascript - the details of which will depend greatly on what you are loading.
If you don't have control over the target page then browser XSS security will (should) prevent you from altering the content of the iframe.
Jun 12, 2011
Liam Wickham says:
I have a problem with the latest upgrade to this macro that I have just installe...I have a problem with the latest upgrade to this macro that I have just installed. After the upgrade the iframe macro fails to work at all. It does not complain about an unknown macro, it simply does not work. Nothing appears. Has anyone else reported this? I cannot think of a single other thing that can explain the problem except upgrading. I have 3.5.1 installed and used the automatic upgrade function of plugins in the confluence plugin section.
Basically my website has just stopped working. Any help much appreciated.
EDIT:
Ok I just rolled back from your latest version to 1.7.0 and my wiki works once more. I wonder if this might be to do with the fact I am using zen templates possibly.