SOLVED Google/Youtube Video In BBCode
Subject: Google/Youtube Video In BBCode
I've got these tags working properly, but I wold like to get icons for them in the reply window. Can anyone give me some pointers on what needs to be edited in order to get them to show up there?
Subject: Re: Google/Youtube Video In BBCode
Last edited by Zuker on Sat 18 Nov, 2006 18:42; edited 1 time in total
- #
- #-----[ UPLOAD ]------------------------------------------
- #
- youtube.gif to images/bbcb_mg/images/gif/
- #
- #-----[ OPEN ]------------------------------------------
- #
- templates/ca_aphrotite/bbcb_mg.tpl
- #
- #-----[ FIND ]------------------------------------------
- #
- <a href="javascript:BBCquick()"><img border="0" src="{BBCB_MG_IMG_PATH}quick{BBCB_MG_IMG_EXT}" name="quick" type="image" onMouseOver="helpline('quick')" alt="Quicktime" title="Quicktime" class="bbimages" /></a>
- #
- #-----[AFTER, ADD]------------------------------------------
- #
- <a href="javascript:BBCyoutube()" accesskey="p"><img border="0" src="{BBCB_MG_IMG_PATH}youtube{BBCB_MG_IMG_EXT}" name="img" type="image" onMouseOver="helpline('youtube')" alt="Youtube" title="youtube" class="bbimages" /></a>
- #
- #-----[ OPEN ]------------------------------------------
- #
- language/lang_english/bbcb_mg.js
- #
- #-----[ FIND ]------------------------------------------
- #
- s_img_error = 'You didn't write the image URL';
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- s_youtube_insert = 'Enter the Youtube video code';
- s_youtube_error = 'You didn't write the Youtube video code';
- #
- #-----[ FIND ]------------------------------------------
- #
- s_image_upload_help = 'Upload image to PostImage.org and add to message';
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- s_youtube_help = 'Insert a Youtube video';
- #
- #-----[ FIND ]------------------------------------------
- #
- '[quote]','[/quote]',
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- '[youtube]','[/youtube]',
- #
- #-----[ FIND ]------------------------------------------
- #
- var Code = 0;
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- var youtube = 0;
- #
- #-----[ FIND ]------------------------------------------
- #
- function BBCcode()
- {
- var txtarea = document.post.message;
- if ((clientVer >= 4) && is_ie && is_win)
- {
- theSelection = document.selection.createRange().text;
- if (theSelection != '')
- {
- document.selection.createRange().text = "[code linenumbers=false]" + theSelection + "[/code]";
- document.post.message.focus();
- return;
- }
- }
- else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
- {
- mozInsert(txtarea, "[code linenumbers=false]", "[/code]");
- return;
- }
- if (Code == 0)
- {
- ToAdd = "[code linenumbers=false]";
- document.post.code.src = bbcb_mg_img_path + "code1" + bbcb_mg_img_ext;
- Code = 1;
- }
- else
- {
- ToAdd = "[/code]";
- document.post.code.src = bbcb_mg_img_path + "code" + bbcb_mg_img_ext;
- Code = 0;
- }
- PostWrite(ToAdd);
- }
- #
- #-----[ BEFORE, ADD]------------------------------------------
- #
- function BBCyoutube()
- {
- var FoundErrors = '';
- var enterURL = prompt(s_youtube_insert, s_url_insert_tip);
- if (!enterURL)
- {
- FoundErrors += s_youtube_error;
- }
- if (FoundErrors)
- {
- alert(s_gen_error + FoundErrors);
- return;
- }
- var ToAdd = "[youtube]"+enterURL+"[/youtube]";
- PostWrite(ToAdd);
- }
Last edited by Zuker on Sat 18 Nov, 2006 18:42; edited 1 time in total
youtube.gif | |
Description: | youtube.gif |
Filesize: | 902 Bytes |
Viewed: | 9324 Time(s) |
![]() |
Subject: Re: Google/Youtube Video In BBCode
That's for youtube ;)
For google video i didn't make anything
For google video i didn't make anything
Subject: Re: Google/Youtube Video In BBCode
Last edited by Zuker on Sun 19 Nov, 2006 22:04; edited 1 time in total
For Google Video
It's based on bbcode
It's based on bbcode
- #
- #-----[ UPLOAD ]------------------------------------------
- #
- googlevideo.gif to images/bbcb_mg/images/gif/
- #
- #-----[ OPEN ]------------------------------------------
- #
- templates/ca_aphrotite/bbcb_mg.tpl
- #
- #-----[ FIND ]------------------------------------------
- #
- <a href="javascript:BBCquick()"><img border="0" src="{BBCB_MG_IMG_PATH}quick{BBCB_MG_IMG_EXT}" name="quick" type="image" onMouseOver="helpline('quick')" alt="Quicktime" title="Quicktime" class="bbimages" /></a>
- #
- #-----[AFTER, ADD]------------------------------------------
- #
- <a href="javascript:BBCgooglevideo()" accesskey="g"><img border="0" src="{BBCB_MG_IMG_PATH}googlevideo{BBCB_MG_IMG_EXT}" name="img" type="image" onMouseOver="helpline('googlevideo')" alt="Google Video" title="Google Video" class="bbimages" /></a>
- #
- #-----[ OPEN ]------------------------------------------
- #
- language/lang_english/bbcb_mg.js
- #
- #-----[ FIND ]------------------------------------------
- #
- s_img_error = 'You didn't write the image URL';
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- s_googlevideo_insert = 'Enter the Google video code';
- s_googlevideo_error = 'You didn't write the Google video code';
- #
- #-----[ FIND ]------------------------------------------
- #
- s_image_upload_help = 'Upload image to PostImage.org and add to message';
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- s_google_help = 'Insert a Google video';
- #
- #-----[ FIND ]------------------------------------------
- #
- '[quote]','[/quote]',
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- '[googlevideo]','[/googlevideo]',
- #
- #-----[ FIND ]------------------------------------------
- #
- var Code = 0;
- #
- #-----[ AFTER, ADD]------------------------------------------
- #
- var googlevideo = 0;
- #
- #-----[ FIND ]------------------------------------------
- #
- function BBCcode()
- {
- var txtarea = document.post.message;
- if ((clientVer >= 4) && is_ie && is_win)
- {
- theSelection = document.selection.createRange().text;
- if (theSelection != '')
- {
- document.selection.createRange().text = "[code linenumbers=false]" + theSelection + "[/code]";
- document.post.message.focus();
- return;
- }
- }
- else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
- {
- mozInsert(txtarea, "[code linenumbers=false]", "[/code]");
- return;
- }
- if (Code == 0)
- {
- ToAdd = "[code linenumbers=false]";
- document.post.code.src = bbcb_mg_img_path + "code1" + bbcb_mg_img_ext;
- Code = 1;
- }
- else
- {
- ToAdd = "[/code]";
- document.post.code.src = bbcb_mg_img_path + "code" + bbcb_mg_img_ext;
- Code = 0;
- }
- PostWrite(ToAdd);
- }
- #
- #-----[ BEFORE, ADD]------------------------------------------
- #
- function BBCgooglevideo()
- {
- var FoundErrors = '';
- var enterURL = prompt(s_googlevideo_insert, s_url_insert_tip);
- if (!enterURL)
- {
- FoundErrors += s_googlevideo_error;
- }
- if (FoundErrors)
- {
- alert(s_gen_error + FoundErrors);
- return;
- }
- var ToAdd = "[googlevideo]"+enterURL+"[/googlevideo]";
- PostWrite(ToAdd);
- }
Last edited by Zuker on Sun 19 Nov, 2006 22:04; edited 1 time in total
googlevideo.gif | |
Description: | googlevideo.gif |
Filesize: | 1.1 KB |
Viewed: | 9305 Time(s) |
![]() |
Subject: Re: Google/Youtube Video In BBCode
wow, you guys are great... and fast!
I'll get this in..
Thanks much!
C
I'll get this in..
Thanks much!
C
Subject: Re: Google/Youtube Video In BBCode
the Google video it's not fully tested, any problem report it please ;)
Subject: Re: Google/Youtube Video In BBCode
Another image for google video bbcode :mrgreen:
googlevideo.gif | |
Description: | googlevideo.gif |
Filesize: | 413 Bytes |
Viewed: | 9263 Time(s) |
![]() |
Subject: Re: Google/Youtube Video In BBCode
Nice work Zuker... I hope to find some free time to fix all new BBCodes in the package. :wink:
Subject: Re: SOLVED -Google/Youtube Video In BBCode
Is there a way to delete "http://" when it asks for youtube or googlevideo code? It's a code, not an URL...
thanks! 8)
thanks! 8)
Page 1 of 1
You cannot post new topicsYou cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events
This is a "Lo-Fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by Icy Phoenix based on phpBB
Generation Time: 0.1498s (PHP: 23% SQL: 77%)
SQL queries: 18 - Debug Off - GZIP Enabled