[Duplicate] MyBB Youtube Video Embedding
This user has been denied support. This user has been denied support.
The returned link is corrupt when using the video tag to embed a YouTube video. This seems to be caused by calling htmlspecialchars_uni on the returned ID.

Examples of corrupt links:
<iframe width="560" height="315" src="//www.youtube.com/embed/wOMwO5T3yT4" target" frameborder="0" allowfullscreen=""></iframe>

<iframe width="560" height="315" src="//www.youtube.com/embed/wOMwO5T3yT4" target="_blank" rel=&quot;noopener&quot; class=&quot;mycode_url&quot;&gt;https://www.youtube.com/watch#wOMwO5T3yT4&lt;/a&gt;" frameborder="0" allowfullscreen=""></iframe>

PHP Version 7.2.4
MyBB Version: 1.8.15
Template: video_youtube_embed

File:        /inc/class_parser.php
Function:    mycode_parse_video
Code:        $id = htmlspecialchars_uni($id);

File:        /inc/functions.php
Function:    htmlspecialchars_uni
Code:        $message = str_replace("\"", "&quot;", $message);

Messages In This Thread
MyBB Youtube Video Embedding - by Yota_Ninja - 2018-04-01, 02:32 AM
RE: MyBB Youtube Video Embedding - by .m. - 2018-04-01, 03:55 AM

Forum Jump:

Users browsing this thread: 1 Guest(s)