Help:ChangeIFRAME

From QED

Jump to: navigation, search

changeIFRAME is an experimental tag for allowing readers to modify the source of an embedded IFRAME on the current page.

Contents

Syntax

 <changeIFRAME page=PAGE title=HOVER iframe=NAME>TEXT</changeIFRAME>

where however only page=PAGE is required.

Semantics

TEXT will be displayed as a hyperlink. In general, when the hyperlink is activated, the IFRAME source will be changed to PAGE, but the exact behavior depends on whether the page exists and whether the user has editing privileges.

Specifically, if the specified PAGE is a reference to a QED page that exists, then the TEXT will appear as a valid hyperlink, and when it is selected, the specified IFRAME will be filled with the contents of that page. If the page does not exist, then the link will be displayed differently, and the behavior will depend on whether the user has permission to create the page.

Notes

  • The default NAME is CalendarFrame.
  • PAGE may take the form Image:foobar.jpg in which case no check is made that the image exists and a simple href is used;
  • otherwise, if PAGE exists, a link to render it is generated (action=render);
  • otherwise, a link to edit it is generated.
  • All the values except NAME are parsed for variable names, including template parameters.

Example

  <changeIFRAME page=http://etc.princeton.edu/films/index.php?date={{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY}}
   title=CURRENT DAY>{{CURRENTYEAR}}-{{CURRENTMONTH}}-{{CURRENTDAY}}
  </changeIFRAME>

together with the <iframe> specification that can be viewed on this page, produces this button:

2009-11-25


Personal tools