Back to vBulletin 3.6 Add-ons

[YouTube] Integration with Links & Downloads Manager (LDM 2.2.6)
Mod Version: 1.00, by |oR|Greg

This modification is in the archives.
vB Version: 3.6.4 Rating: (1 vote - 5.00 average) Installs: 36
Released: 28 Nov 2006 Last Update: Never Downloads: 94
Not Supported Uses Plugins Template Edits Code Changes  

Intro/About:
If you're not familiar with Links and Downloads Manager you should be! It's one of the most robust hacks for http://www.vbulletin.com out there and allows you the Administrator to add vast amounts of content to your board on your own, or via your board members. This hack, for LDM 2.2.6 and vB 3.6.X will allow your links to YouTube videos to play inline within LDM.

This hack requires:
  • 1 template edit (AdminCP ==> Styles & Templates ==> Styles Manager ==> (your style) ==> Links and Downloads Manager ==> links_playbit)
  • 1 file edit (./includes/local_links_include.php)
  • 1 new plugin
  • 1 new gif file
So, let's get started, this whole process should take no more then 5 minutes, and please make sure you backup before you start, I am not responsible if you somehow hose your site. (Although this is such a small mod I can't imagine you could, but I've been wrong before)

In your links_playbit template find:
HTML Code:
<td align="center">
Add AFTER:
HTML Code:
<if condition="$player=='youtube'">
			<object width="425" height="340" type="application/x-shockwave-flash" data="http://www.youtube.com/v/$url">
				<param name="movie" value="http://www.youtube.com/v/$url" />
				<param name="wmode" value="transparent" />
				<em><strong>ERROR:</strong> If you can see this, then <a href="http://www.youtube.com/">YouTube</a> is down or you don't have Flash installed.</em>
			</object>
</if>
The above width and height can of course be altered to suit your needs.

In your ./includes/local_links_include.php file find (around line 2590):
PHP Code:
            $musicbox_template    '<a href="'.$LINKS_SCRIPT.'.php?action=play&amp;linkid='.$linkid.'&amp;catid='.$linkcatid.'&amp;page='.$pagenumber.'" '.$musicbox_window.' title="'.$vbphrase['ll_playme'].'">%s</a>'
Add AFTER:
PHP Code:
            if(stristr($linkurl'youtube.com/watch?v=')) {
            
$lc_urlType "youtube";
            
$is_musicbox 1;
            } 
Great! The hard part is over! Now, add the included Plugin, and upload the gif image to your Links and Downloads Icon Cache, for me, my Icon Cache is located at http://www.amacny.com/vb/images/ldm it's the directory where all your extension gifs are located. Make sure that the Plugin is turned ON. You should now be able to add entries to LDM for YouTube, and have them play within your own website!

Live Demo/Example: http://www.amacny.com/vb/local_links.php?catid=53&linkid=506

If you're getting an error stating that it's an Invalid Filetype. Go into your LDM settings, and edit 1 of these options, either: musicbox_filetypes, or musicbox_filetypes_divx, or musicbox_filetypes_quicktime, or musicbox_filetypes_realplayer. Remove ALL entries in the setting you choose.

Until I can make this mini-mod work WITH all those settings intact, this is the quick-fix. Chances are you're not using ONE of those players.

Don't forget to click

Download

This modification is archived, downloads are still allowed.

File Type: %1$s LDM-YouTubeInline-plugin.xml (736 Bytes, 171 downloads)

Screenshots

Click image for larger version
Name:	youtube.JPG
Views:	1390
Size:	49.2 KB
ID:	56851  

Similar Mods

Major Additions Links and Downloads Manager vBulletin 3.7 Add-ons
Major Additions Links and Downloads Manager vBulletin 3.6 Add-ons
Links and Downloads Manager vBulletin 3.5 Add-ons

vblts.ru supports vBulletin®, 2022-2024