aboutsummaryrefslogtreecommitdiff
path: root/doc/plugins/embed.mdwn
blob: 85592cb722ca1bf2f185e4b64989736ae920811f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
[[!template id=plugin name=embed author="[[Joey]]"]]
[[!tag type/html]]

This plugin allows embedding content from external sites on 
wiki pages.

Normally, the [[htmlscrubber]] does not allow the tags that are used for
embedding content from external sites, since `<iframe>`, `<embed>`, and
`<object>` tags can be used for various sorts of attacks. This plugin
allows such tags to be put on a page, if they look like they are safe.

In the examples below, the parts of the html that you can change are denoted
with "XXX"; everything else must appear exactly as shown to be accepted by the
plugin.

**This plugin is deprecated.** Rather than relying on these complex lists
of safe content, which constantly fall out of date, you're recommended to
configure the [[htmlscrubber]] to not scrub some pages, which only trusted
users can edit. Then you can embed anything from anywhere on those pages.
See [[tips/embedding_content]] for details and examples.
This plugin's lists of safe embedded content will not be maintained, and 
the plugin will be removed in a future  release.

## google maps

Use html like this to embed a map:

	<iframe width="XXX" height="XXX" frameborder="XXX" scrolling="XXXX" marginheight="XXXX" marginwidth="XXXX" src="http://maps.google.com/?XXX"></iframe>

(This method only allows embeddeding a simple map. To use the full
[Google Maps API](http://www.google.com/apis/maps/) from ikiwiki, including
drawing points and GPS tracks on the map, try the [[contrib/googlemaps]]
plugin.)

## youtube

Use html like this to embed a video:

	<object width="XXX" height="XXX"><param name="movie" value="http://www.youtube.com/v/XXX"></param><param name="wmode" value="transparent"></param>
	<embed src="http://www.youtube.com/v/XXX" type="application/x-shockwave-flash" wmode="transparent" width="XXX" height="XXX"></embed></object>

## google video

Use html like this to embed a video:

	<embed style="width:XXXpx; height:XXXpx;" id="XXX" type="application/x-shockwave-flash" src="http://video.google.com/googleplayer.swf?XXX" flashvars=""></embed>

## google calendar

Use html like this to embed a calendar:

	<iframe src="http://www.google.com/calendar/embed?XXX" style="border-width:XXX" width="XXX" frameborder="XXX" height="XXX"></iframe>