2009-07-24, 10:16 AM
(This post was last modified: 2013-05-10, 09:54 AM by querschlaeger.)
Hi,
this simple MyCode will embed a YouTube video (ok, nothing special...) but with the "new" popup support by Youtube!
Regex:
Replacement:
Usage:
Demo: Short Films (click on the image at the top on the right of a video)
(or view this screenshot)
this simple MyCode will embed a YouTube video (ok, nothing special...) but with the "new" popup support by Youtube!
Regex:
\[youtube\](.*?)\[/youtube\]
(or whatever you want)Replacement:
<div style="margin:0;padding:0;width:512px;"><div style="float:right;"><button onclick="MyBB.popupWindow('http://www.youtube.com/watch_popup?v=$1','youtube_$1',640,480);" style="background:url(http://s.ytimg.com/yt/img/master-vfl102488.png) 0 -658px;border:0;height:22px;width:27px;" /></div><object type="application/x-shockwave-flash" data="http://www.youtube.com/v/$1&fs=1&rel=0" width="512" height="384"><param name="movie" value="http://www.youtube.com/v/$1&fs=1&rel=0" /><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="wmode" value="transparent" /></object></div>
Usage:
[youtube]i9Z8gW8NBks[/youtube]
(it's the video ID by youtube)Demo: Short Films (click on the image at the top on the right of a video)
(or view this screenshot)