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
aspmwiki/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]] %% |
|
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.