vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   BBcode you tube (https://vborg.vbsupport.ru/showthread.php?t=207440)

dxflw 03-05-2009 03:41 PM

BBcode you tube
 
How do i add custom bbcode for youtube links but only for the full youtube URL
i.e.: http://www.youtube.com/watch?v=rxVS5nYFnkA

I don't mean the the last part of the URL(i.e.:rxVS5nYFnkA)

I search the vbulletin.org but i find bbcode only for the last part of the youtube url.

I don't wanna use any addo'n i want use a custom bbcode about.

Lynne 03-05-2009 03:44 PM

Did you try doing a search here? There are several different bbcodes in the mods forum for youtube links.

dxflw 03-06-2009 11:49 AM

Yes i search the vbulletin.org but the only i found is not for the full URL but is only for the last part of the URL i.e. [youtube]fdhjkaa[/youtube]
I want to use it with the full URL i.e. [youtube]http://www.youtube.com/watch?v=rxVS5nYFnkA[/youtube]

Lynne 03-06-2009 01:53 PM

Modify it to do what you want.

Spank 03-06-2009 01:58 PM

AME does what you want. Works with youtube and loads of other sites.

https://vborg.vbsupport.ru/showthread.php?t=195884

ZombieAndy 03-06-2009 04:57 PM

You can make a simple edit to the standard code to make it accept the full URL instead of just the code, for example my youtube vid code is:

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="1">
<
tbody>
<
tr>
<
td class="tcat" colspan="2">
<
div align="left"><a target="_blank" href="http://uk.youtube.com/watch?v={param}">Youtube Video</a></div>
</
td>
</
tr>
</
thead>
<
tr>
<
td class="alt2" colspan="2"><param name="movie" value="http://www.youtube.com/v/{param}"></param><embed src="http://www.youtube.com/v/{param}" type="application/x-shockwave-flash" width="395" height="331"></embed></object><br>
</
td>
</
tr>
</
tbody>
</
table

That just uses the video code from the end of the URL, but you could edit it to

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="1">
<
tbody>
<
tr>
<
td class="tcat" colspan="2">
<
div align="left"><a target="_blank" href="{param}">Youtube Video</a></div>
</
td>
</
tr>
</
thead>
<
tr>
<
td class="alt2" colspan="2"><param name="movie" value="http://www.youtube.com/v/{param}"></param><embed src="{param}" type="application/x-shockwave-flash" width="395" height="331"></embed></object><br>
</
td>
</
tr>
</
tbody>
</
table

And that will now take the full URL instead.

:)

c.c. 03-25-2009 11:58 AM

Quote:

Originally Posted by ZombieAndy (Post 1761892)
You can make a simple edit to the standard code to make it accept the full URL instead of just the code, for example my youtube vid code is:

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="1">
<
tbody>
<
tr>
<
td class="tcat" colspan="2">
<
div align="left"><a target="_blank" href="http://uk.youtube.com/watch?v={param}">Youtube Video</a></div>
</
td>
</
tr>
</
thead>
<
tr>
<
td class="alt2" colspan="2"><param name="movie" value="http://www.youtube.com/v/{param}"></param><embed src="http://www.youtube.com/v/{param}" type="application/x-shockwave-flash" width="395" height="331"></embed></object><br>
</
td>
</
tr>
</
tbody>
</
table

That just uses the video code from the end of the URL, but you could edit it to

PHP Code:

<table class="tborder" cellpadding="$stylevar[cellpadding]cellspacing="$stylevar[cellspacing]border="1">
<
tbody>
<
tr>
<
td class="tcat" colspan="2">
<
div align="left"><a target="_blank" href="{param}">Youtube Video</a></div>
</
td>
</
tr>
</
thead>
<
tr>
<
td class="alt2" colspan="2"><param name="movie" value="http://www.youtube.com/v/{param}"></param><embed src="{param}" type="application/x-shockwave-flash" width="395" height="331"></embed></object><br>
</
td>
</
tr>
</
tbody>
</
table

And that will now take the full URL instead.

:)

This doesn't work. I've been searching for a full url bbcode for months!!! Is there anyone that can help me on modifying this code so it works?

Basically what do I change in this code so I could use the full url when embed you tube?
Quote:

<object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/{param}"></param><embed src="http://www.youtube.com/v/{param}" type="application/x-shockwave-flash" width="425" height="350"></embed></object>

Lynne 03-25-2009 02:04 PM

You change where it says "value" and where it says "src". value="{param}" and src="{param}"

c.c. 03-25-2009 02:23 PM

So basically it should look like this:

<object width="425" height="350"><param name="movie" value="{param}"></param><embed src="{param}" type="application/x-shockwave-flash" width="425" height="350"></embed></object>

when I use this code it just give me a white screen. Nothing comes up.

Lynne 03-25-2009 03:14 PM

You need to use all the other code there too. If it doesn't work, you'll have to look at your page source and see what is going on.


All times are GMT. The time now is 01:32 AM.

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.01134 seconds
  • Memory Usage 1,772KB
  • 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
  • (4)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete