Page 1 of 1

bbcode for Forum

Posted: 10 Sep 2009 16:52
by Pikeman
Hi guys,

first of all, sorry for my bad english!!
But I will try to explain my problem.

I'm trying to make a bbcode for my forum. With this bbcode it should be possible to stream a short avi file to the clients.
But there are some problems. In Firefox the stream looks very fine. But when I try to control the stream/player (Play, Stop, Pause) the whole page will be reloaded.
With Opera nothing is shown!!! Only a black box and no pics for control!!

Well, I'm not a programmer, but I want this bbcode get working in my forum!!!

The bbcode looks like:

Code: Select all

[SAMPLE]NAME_OF_FILE.avi[/SAMPLE]
And here is the code for the bbcode:

Code: Select all

<embed type="application/x-vlc-plugin" pluginspage="http://www.videolan.org" version="VideoLAN.VLCPlugin.2" width="624" height="256" id="vlc"> </embed> <script language="Javascript"> <!-- var vlc=document.getElementById("vlc"); var id=vlc.playlist.add("http://URL_TO_AVI_FILES/{param}"); vlc.playlist.playItem(id); </script> </br> <br> <a href="#" onclick='vlc.playlist.play()'><img src="http://URL_TO_PICS/play.png" border="0" ></a> <a href="#" onclick='vlc.playlist.togglePause()'><img src="http://URL_TO_PICS/pause.png" border="0" ></a> <a href="#" onclick='vlc.playlist.stop()'><img src="http://URL_TO_PICS/stop.png" border="0" ></a> <a href="#" onclick='vlc.video.toggleFullscreen()'><img src="http://URL_TO_PICS/full.png" border="0" ></a>
Pleas help me to get this problem fixed.
Thank you very much!!

Greetz

Pikeman

Re: bbcode for Forum

Posted: 13 Sep 2009 20:24
by Arite
Not entirely sure what was wrong however I tweaked it a bit based on the simple VLC example here however it seems to work OK. Made it a bit more XHTML friendly too.

Here is the HTML code (for an entire webpage linking to the Big Buck Bunny video):

Code: Select all

<html>     <head>     </head>     <body>         <embed type="application/x-vlc-plugin" pluginspage="http://www.videolan.org" version="VideoLAN.VLCPlugin.2"             width="624" height="256" id="vlc1" />              <script language="javascript">             var vlc1 = document.getElementById("vlc1");             var url = "http://vlc.Revolunet.Com/Dessin_Anime_BigBuckBunny_HD.avi";             var id1 = vlc1.playlist.add(url, url, "");             vlc1.playlist.play(id1);         </script>         <br />         <br />         <a href="#" onclick='vlc1.playlist.play()'><img src="http://URL_TO_PICS/play.png" alt="Play" border="0" ></a>         <a href="#" onclick='vlc1.playlist.togglePause()'><img src="http://URL_TO_PICS/pause.png" alt="Pause" border="0" ></a>         <a href="#" onclick='vlc1.playlist.stop()'><img src="http://URL_TO_PICS/stop.png" alt="Stop" border="0" ></a>         <a href="#" onclick='vlc1.video.toggleFullscreen()'><img src="http://URL_TO_PICS/full.png" alt="Fullscreen" border="0" ></a>     </body> </html>
And for BBCode:

Code: Select all

<embed type="application/x-vlc-plugin" pluginspage="http://www.videolan.org" version="VideoLAN.VLCPlugin.2"     width="624" height="256" id="vlc1" />      <script language="javascript">     var vlc1 = document.getElementById("vlc1");     var url = "http://URL_TO_AVI_FILES/{param}";     var id1 = vlc1.playlist.add(url, url, "");     vlc1.playlist.play(id1); </script> <br /> <br /> <a href="#" onclick='vlc1.playlist.play()'><img src="http://URL_TO_PICS/play.png" alt="Play" border="0" ></a> <a href="#" onclick='vlc1.playlist.togglePause()'><img src="http://URL_TO_PICS/pause.png" alt="Pause" border="0" ></a> <a href="#" onclick='vlc1.playlist.stop()'><img src="http://URL_TO_PICS/stop.png" alt="Stop" border="0" ></a> <a href="#" onclick='vlc1.video.toggleFullscreen()'><img src="http://URL_TO_PICS/full.png" alt="Fullscreen" border="0" ></a>
Haven't tested it with the BBCode (also not sure which forum package you are using).

Arite.

Re: bbcode for Forum

Posted: 16 Sep 2009 20:33
by Pikeman
Hi,

thx. Now the buttons are alright in Opera.
But the stream doesn't start. Only Firefox will start the stream correct.
My Forum Software is vBulletin 3.8.2

I can't find out why opera doesn't start. When I try the HTML Code, everything is fine in both browsers.
But when I will try it in vB with bbcode, only Firefox will play.
In Opera black box with WAITING FOR VIDEO can be seen.

Please help....

Greetz

Pikeman

Re: bbcode for Forum

Posted: 17 Sep 2009 02:43
by Arite
Does the Simple VLC plugin test playback correctly in Opera? If so compare the JavaScript etc.

Arite.

Re: bbcode for Forum

Posted: 20 Sep 2009 16:16
by Pikeman
Hi,

the link is working fine under Opera.
But I don't understand it when you say: If so compare the JavaScript etc.

What I have to compare?? I didn't change anything in a JavaScript or something.

Can you help me one more time please?

Greetz

Pikeman

Re: bbcode for Forum

Posted: 20 Sep 2009 19:18
by Arite
What I have to compare?? I didn't change anything in a JavaScript or something.
I just meant look at the source code for the Simple VLC plugin example, and see how it differs from your own. If the simple VLC plugin example works in Opera and yours doesn't hopefully it just involve tweaking some bit of code to make it work.
Can you help me one more time please?
Well I just tried my code in Opera (10) and it works fine using the example HTML code I posted above.

Arite.

Re: bbcode for Forum

Posted: 29 Oct 2009 08:49
by aristana
Can I get a chatbox is the form of CSS or BBcode? I'm working on a custom profile, but I need a chatbox, and sadly, the site only accepts BBcode and CSS.

MOD EDIT: Removed spam at bottom of post.

Re: bbcode for Forum

Posted: 29 Oct 2009 15:02
by Arite
Is this VLC related? There are things like AJAX chatboxes available which you could embed, or you could write something in Javascript or PHP etc.

Arite.

Re: bbcode for Forum

Posted: 06 Jan 2010 17:23
by aymen99
i think there is an addon for phpbb,just add it and it will appear in bbcode