YouTube Default Embed Size

nguyenac

Administrator
Thành viên BQT
#1
Go to:
ACP > Content > BB Code media sites.

Then disable current YouTube BB code.

After that click here:

Fill the form:
Media site id: youtube_custom

Site title: YouTube

Site URL:
You do not have permission to view link Đăng nhập hoặc Đăng ký.


Match URLs:
Mã:
youtube.com/watch?v={$id}
youtube.com/watch?*&v={$id}
youtube.com/v/{$id}
youtu.be/{$id}
youtube.com/*/u/*/{$id}
youtube.com/embed/{$id}
Embed template:
HTML:
<div class="bbMediaWrapper">
    <div class="bbMediaWrapper-inner">
        <iframe src="https://www.youtube.com/embed/{$id}?wmode=opaque&start={$start}"
                width="800" height="600"
                frameborder="0" allowfullscreen="true"></iframe>
    </div>
</div>
Then open Advanced options tab in the same form:

URL match callback: XF\BbCode\Helper\YouTube :: matchCallback

Embed HTML callback : XF\BbCode\Helper\YouTube :: htmlCallback

Hit Save and exit.
 

Facebook Comment

Tài nguyên mới

Top Bottom