vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   BB Code Enhancements - [BB Code] YouTube Javascript Embed (https://vborg.vbsupport.ru/showthread.php?t=205783)

wii 02-17-2009 10:00 PM

[BB Code] YouTube Javascript Embed
 
1 Attachment(s)
Show YouTube videos directly in your vBulletin forum posts.
Very easy to install and please Mark as Installed if you decide to use it, thanks.

Changes to my old YouTube embed:

1. All videos are now larger (640x480 pixels)
2. All videos are now shown in high quality and stereo sound (if available)
3. You can now embed videos in HD (if available)
4. Valid XHTML code (works in all modern browsers and operating systems).

Installation is as follows:

1. Go To AdminCP.
2. Select Custom BB Codes.
3. Add New BB Code.
4. Fill in the following:

Title: YouTube BB Code
Tag: yt
Replacement:

HTML Code:

<script src="http://www.yourforum.com/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript" >
AC_FL_RunContent('codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0','width','640','height','480','src','http://www.youtube.com/v/{param}&ap=%2526fmt%3D18','quality','high','wmode','transparent','name','youtube','allowscriptaccess','sameDomain','pluginspage','http://www.macromedia.com/go/getflashplayer','movie','http://www.youtube.com/v/{param}&ap=%2526fmt%3D18' );</script>


5. Upload the included javascript file to your forum root:
Change the example URL: www.yourforum.com to your own URL.

6. Edit the code above to the exact location of the javascript file you just uploaded.

Example: [yt]1EutKrKTfLk[/yt]
Description: YouTube
Use {Option}: No

When installed, use the code in your forum like this:

HTML Code:

[yt]1EutKrKTfLk[/yt]
For HD use this:

HTML Code:

[yt]1EutKrKTfLk&amp;ap=%2526fmt%3D22[/yt]

wii 02-18-2009 11:53 AM

I will upload the files now.

Stifmeister2 02-18-2009 07:20 PM

Demo anywhere?

ABDALWAHID 02-18-2009 08:09 PM

Thanks...

GotWalked 02-18-2009 09:36 PM

terrible. couldn't get it to work

wii 02-19-2009 06:16 AM

I uploaded some screenshots, the MOD works just fine, just make sure the path to the javascript file is correct.

For my own forum I use the MOD with a different movie size of 640x384 pixels (widescreen format) this way I have no borders when viewing HD widescreen movies, which we use a lot.

Also note, that this MOD forces YouTube videos into high quality at all times, which means that many tracks that are mono when viewing in YouTube are in stereo when viewing at the forum, this was kinda a surprise for me too, but it's a quite obvious difference, of course only applies when the source material is in stereo...!

newmasalaboard 02-19-2009 09:12 AM

Looks Intresting !!

Let me test it ...

ByG SteAm 02-22-2009 08:12 PM

Where do we find the text on a youtube video for HD. I can see where you get the regular code from.

wii 02-23-2009 09:20 AM

What text ? Not sure what you mean.......

movslow 02-23-2009 06:28 PM

Great mod, however are their any current hacks that conflict w/this mod?

I'm just getting a blank screen where the video should be.
:confused:

wii 02-24-2009 07:53 AM

Did you check the filepath of the included file ?
Can I see an example of it where you see the blank page ?

black_bullitt 03-04-2009 12:52 AM

Installed, working great, thanks!

wii 03-05-2009 02:12 PM

Glad you like it...

dpetersman 03-05-2009 04:49 PM

I'm kinda an idiot & it took me a few try's to get it to work. After I realized all I needed to input as the value was the specific video #, Worked like a charm :o

To save anyone else the embarrassment, here's what I mean...

typical YouTube video URL's look like this:

Code:

http://www.youtube.com/watch?v=1EutKrKTfLk
All you need is the text after the "v=" in the case of the link above, "1EutKrKTfLk" is what you would put between the [yt ][ /yt] BB code (without the "Quotes") Like this:
Code:

[yt]1EutKrKTfLk[/yt]


Anyway, Works Great. I love it. Thanks!

Slacker 03-06-2009 08:37 PM

I would love something like there where the user could enable/disable the tag (like we can all do with IMG tags) in their User CP so people browsing at work aren't setting off alarms on the company's monitoring software. Any chance of that happening? Thanks!

guncanada 03-15-2009 01:31 PM

works great. But how can i install a button that can put the tags around for the users. Like a little youtube button so it will pop up a window where they can copy the youtube url

vijayninel 03-18-2009 03:36 AM

This is awesome but...Right now the system system we have on our forums is that the user just copies and pastes the url link of the video and the video shows up on the page when posted......no inserting between the bb codes and manually putting the end part.

Can something like that be done with this.

Thanks. :)

A Random Otaku 06-12-2009 09:31 AM

Quote:

Originally Posted by movslow (Post 1752550)
Great mod, however are their any current hacks that conflict w/this mod?

I'm just getting a blank screen where the video should be.
:confused:


This was blank because of a mistake in the code.

Here is the original:

<script src="http://www.yourforum.com/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript" >
AC_FL_RunContent('codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0','width','640','height ','480','src','http://www.youtube.com/v/{param}&ap=%2526fmt%3D18','quality','high','wmode' ,'transparent','name','youtube','allowscriptaccess ','sameDomain','pluginspage','http://www.macromedia.com/go/getflashplayer','movie','http://www.youtube.com/v/{param}&ap=%2526fmt%3D18' );</script>

Here is the fix:

<script src="http://www.yourforum.com/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript" >
AC_FL_RunContent('codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0','width','640','height ','480','src','http://www.youtube.com/v={param}&ap=%2526fmt%3D18','quality','high','wmode' ,'transparent','name','youtube','allowscriptaccess ','sameDomain','pluginspage','http://www.macromedia.com/go/getflashplayer','movie','http://www.youtube.com/v/{param}&ap=%2526fmt%3D18' );</script>

I erased the forward slash after the youtube.com/v and added a = in the front. Works perfect now. I've turned the fixed part red so you can find it easier.

So if anybody has a blanking problem, try that.

Good BB Code. Installed :D

Nosfer@tu 06-14-2009 08:10 AM

Quote:

Originally Posted by vijayninel (Post 1770892)
This is awesome but...Right now the system system we have on our forums is that the user just copies and pastes the url link of the video and the video shows up on the page when posted......no inserting between the bb codes and manually putting the end part.

Can something like that be done with this.

Thanks. :)

How do you do that ?
it REALLY sux when the code cant even crap the excessive url into what it needs.
Very long educational process for the users.

wafa 09-10-2009 01:36 AM

thank you ..

it's work with me .

g4dual 02-15-2011 10:01 AM

Thanks !! :D

el-q6ri 05-10-2011 07:28 AM

is this code display the related video if yes how to stop it from loading the related video at the end ?


All times are GMT. The time now is 07:58 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01747 seconds
  • Memory Usage 1,764KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (3)bbcode_html_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (22)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete