Web Design that taps into the haromny and vision of your dreams.

Embed YouTube Videos to phpBB

How to embed youtube videos in phpBB

Written By on in PHP

330 words, estimated reading time 2 minutes.

Embed YouTube videos in bulletin board software such as phpBB, which will not allow you to use the embed code provided by YouTube. This simple tutorial will show you how you and your visitors can link embed videos in posts with a very simple bbcode tag.

This tutorial is aimed at phpBB version 3, although a similar technique may be used for SMF.

PhpBB 3 features a new custom BBCode tag editor which allows you to create custom tags. Here is how it is done.

First, log into your Administrative Control Panel (ACP) and click on the Posting tab on the top menu.

Embed YouTube in phpBB posts
Embed YouTube in phpBB posts

Click the "Add a new BBCode" button in the bottom right-hand corner. (Note: The "youtube" item as shown in the photo below, won't appear at this point on your forum - we are going to create it)

How to Add YouTube Videos to phpBB
How to Add YouTube Videos to phpBB

Enter the following code into the "bbcode usage" box:

[youtube]{SIMPLETEXT}[/youtube]

Enter the following in the "HTML replacement" box. This is essentially the embed code from the YouTube page. Notice the video id has been replaced with {SIMPLETEXT}.

<object width="425" height="350">
  <param name="movie" value="http://www.youtube.com/v/{SIMPLETEXT}&hl=en_US&fs=1&"></param>
  <param name="allowFullScreen" value="true"></param>
  <param name="allowscriptaccess" value="always"></param>
  <embed src="http://www.youtube.com/v/{SIMPLETEXT}&hl=en_US&fs=1&" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="350"></embed>
</object>
 

Finally enter this code into the help line text box:

Insert YouTube Video ID# - Example: [youtube]Hue_h4nsi[/youtube]

You can check "Display on posting page" to add a button to the posting page.

Click submit and that is now done.

How to Add YouTube Videos to phpBB
How to Add YouTube Videos to phpBB

You can simply embed a YouTube video by using

[youtube]AixMDvKuxqU[/youtube]

Where AixMDvKuxqU is the video id from the YouTube URL.

How to Add YouTube Videos to phpBB
How to Add YouTube Videos to phpBB

Last updated on: Wednesday 21st June 2017

 

Comments

There are no comments for this post. Be the first!

 

Leave a Reply

Your email address will not be published.





If you find something abusive or that does not comply with our terms or guidelines please flag it as inappropriate.

Copyright © 2001-2018 Tim Trott, all rights reserved. Web Design by Azulia Designs

This web page is licensed for your personal, private, non-commercial use only.

Disclaimer, Privacy & LegalSitemapContact Me