Iframes

Every WLC site should have a page called „Iframe“ with an „Iframe“ page template. A page with this template cannot be deleted by anyone but the superusers These are known addresses of iframe pages:

Using the iframe page

To call an action on an iframe page simply pass a GET argument called action. e.g.: Showing a personality test https://www.welovecycling.com/wide/iframe/?action=personality_test

Modifying the iframe page

By default the page has no header and footer, you can include these by passing GET arguments

  • includeHeader=true
  • includeFooter=true

i.e.: https://www.welovecycling.com/wide/iframe/?action=personality_test&includeHeader=true&includeFooter=true

Development information

The iframe page shows content based on registered action. As a security measure it is not possible to call just any wordpress action.

Register actions

To register actions for an iframe page you can use a wordpress action hook register_iframe_action. The action receives two arguments, first is the name of the action, second is a callback. You can register multiple callbacks to the same action and they will be executed consecutively (no priorities, first in - first out)