Ape-GenericFrame

Back to Ape, Ape-Sandbox, Cookbook:Ape.

How can we enable the occasional embedding of frames from websites that are not worth adding to the full APE recipe?

To enable this, add a custom rule:

  • Copy the file pmwiki/pub/ape/ape-local-sample.js as pmwiki/pub/ape/ape-local.js (if the latter doesn't exist).
  • Add to bottom of ape-local.js the following line:
  uAPErx.push([ /(https:\/\/.*?)\#ape-generic-frame$/i, '$1']);

Then in the wiki page, embed the full iframe URL with the suffix #ape-generic-frame:

%embed width=600px height=600px% [[https://galleries.accent.bg/Cookbook/Ape-Iframe#ape-generic-frame|Motorcycle gallery]] %%

Motorcycle gallery

Note that if you enable this, all your editors will be able to embed any external website that allows remote embedding, including pornography and other objectionable content, and the remote websites will be able to track your visitors (like YouTube and the other core platforms). In addition, you should more frequently review your pages in case some of the remote websites have disappeared or changed.

This should only be used for URLs designed to be embedded in an iframe, otherwise links from the frame may open in the same frame, see Wikipedia link example. In a more general way recent browsers will by default refuse to embed most recent websites in a frame, unless they have been configured to allow this.

See also Cookbook:Ape#custom-rules.

0: 00.00 MarkupToHTML begin
1: 00.00 MarkupToHTML begin
2: 00.00 MarkupToHTML end
3: 00.03 MarkupToHTML end
4: 00.04 MarkupToHTML begin
5: 00.09 MarkupToHTML end
6: 00.09 MarkupToHTML begin
7: 00.10 MarkupToHTML end
8: 00.10 now