It's better when it's simple

User Tools

Site Tools


YouTube v2 Plugin

Compatible with DokuWiki


plugin Plugin that creates a link or an embed object of YouTube movie with thumbnails and AJAX.

Last updated on
Conflicts with

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

The following security issue was reported for this extension: XSS vulnerability allows arbitrary JavaScript insertion. No contact details for the author identified.

It is not recommended to use this extension until this issue was fixed. Extension authors should read the plugin security guidelines

Similar to flashplayer, flowplay, google_video, video, youtube

Tagged with embed, flash, movie, video, youtube

By Jason T

This DokuWiki plugin can do the following by providing a movie ID and some simple syntax:

  1. Create a link to a YouTube video with/without thumbnail(s)
  2. Embed a large video with/without thumbnail(s)
  3. Embed a small video with/without thumbnail(s)

Additionally when you click a thumbnail (if using one) it will hide the thumbnail and then show the video in the same page. Great for that web 2.0 craving you have.

Thanks to Ikuo Obataya for version 1


  1. For link to a video on YouTube:
  2. For embedding a small video:
  3. For embedding a large video:

Replace “numbThumbs” with the number of image thumbnails you wish to have. Possible values are 0,1,2 (YouTube limits, not mine).

Required Header Code

The following JavaScript must be put into the header file (mine is 'main.php), between the

<head></head> tags. This code handles the hiding and displaying of the images/videos.

<script type="text/javascript">
var clicked=true;
function ExpandCollapse(bExpand,id){
		clicked = bExpand
		document.getElementById(_contents).style.display = 'block';
		document.getElementById(_contents).style.display = 'none';



Download the plugin package and create a directory named 'youtube'. Then extract the plugin into your 'lib/plugins/youtube' directory.

The files in the plugin are:

  1. syntax.php
  2. youtube.png
  3. b_collapse.gif
  4. b_expand.gif


It is not possible to download this plugin with:

cd /usr/local/www/dokuwiki/lib/plugin
fetch "url_of_youtube_plugin.tgz"
tar xvzf youtube

The above code works with all other plugins, but not with this one, since it is hosted by RapidShare.

Download the file using opera web browser [ed]

It is better than the v1 because the thumbnails appears in the rss feed, but the links to show and hide video are not set right: they are relatives to the feed.


plugin/youtubev2.txt · Last modified: 2015-06-24 23:49 by Klap-in