## Wiki

### YouTube embed appears twice in a wiki

This discussion has been locked because a year has elapsed since the last post. Please start a new discussion topic.
YouTube embed appears twice in a wiki

I don't know if this should be reported as a bug. Here's what I just discovered after a teacher reported that an embeded (with Multimedia filter) YouTube video was displayed twice in a wiki.

If you use the URL as the link text, it will be converted to a hyperlink in the wiki, causing a double link.

Like this:

<p><a href="http://www.youtube.com/watch?v=W4uipnBkj-4">http://www.youtube.com/watch?v=W4uipnBkj-4</a></p>

You must replace the text to fix it:

Using Moodle 2.6.2

Average of ratings: -
Re: YouTube embed appears twice in a wiki
Is it the same problem discussed in here: A <nofilter> tag in the forum? https://moodle.org/mod/forum/discuss.php?d=218330 ?

The solution I found is linked to the last post in that thread.

Average of ratings: -
Re: YouTube embed appears twice in a wiki

Similar answer to the one from Visvanath

Have you tried turning off the autolink filter for the wiki?  Should be doable from Administration block -> Wiki administration -> Filters

Ensure you turn off the filter "Convert URLs into links and images".

Otherwise, when editing the wiki page with the TinyMCE editor on, select the link and click the "No auto link" icon.

Hope this helps!

Average of ratings: Useful (1)
Re: YouTube embed appears twice in a wiki

Thanks a lot for your replies. Sorry to get back so late. I just had a baby.

I cannot see how to disable wiki autolinking in Moodle 2.6. There is no wiki filter and no global settings for wiki activity.

François

Average of ratings: -
Re: YouTube embed appears twice in a wiki
Hi

I don't know what "wiki autolinking" is. Those huge video shots appear due to the https://docs.moodle.org/en/Multimedia_plugins_filter. My work-around was linked to my previous post.

Average of ratings: -
Re: YouTube embed appears twice in a wiki

I got around this by entering something other than the URL as the text of the link.

In html, your href should look something like this (with "video" being variable, as long as it isn't the url of the youtube video):

<a>href="https://youtu.be/K1hbhuUdjWU">video</a>

Not like this:

<a>href="https://youtu.be/K1hbhuUdjWU">

Average of ratings: Useful (1)