Firefox PHP

Module: BB Code Video

Posted by Maurice Makaay 
Re: Module: BB Code Video
August 09, 2007 08:43AM
Maybe it's a problem with accessing the jslib. The editor tools take care of adding the registered lib to the page, but it might be that you cannot access .js files, because of the .htaccess restriction in the mods directory. Please add a file ".htaccess" to the bbcode_video mod directory, and put the following in it:
<Files ~ "\.(js|gif)$">
    Order allow,deny
    Allow from all
</Files>


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: BB Code Video
August 09, 2007 09:05AM
Quote
mmakaay
Maybe it's a problem with accessing the jslib. The editor tools take care of adding the registered lib to the page, but it might be that you cannot access .js files, because of the .htaccess restriction in the mods directory. Please add a file ".htaccess" to the bbcode_video mod directory, and put the following in it:
<Files ~ "\.(js|gif)$">
    Order allow,deny
    Allow from all
</Files>
it's not a server side issue. the script code isn't in the headers.. others are, so it's just striking me as odd that these aren't.

<script type="text/javascript" src="[www.SITENAME.DOM] rel="stylesheet" type="text/css" href="[www.SITENAME.DOM] rel="stylesheet" href="[www.SITENAME.DOM] type="text/javascript" src="[www.SITENAME.DOM] type="text/javascript">max_inline_attachment_width=0</script><style type="text/css">
Re: Module: BB Code Video
August 09, 2007 11:59AM
So, did you actually try this .htaccess or are you guessing that this not the problem?

I wonder, because if you are looking at the page headers, you are looking at the wrong spot. This javascript library is added near the footer of the page. This is arranged for from the before_footer hook in the editor_tools module:
<script type="text/javascript"
 src="[localhost];


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: BB Code Video
August 09, 2007 12:39PM
and what is about links from url [vimeo.com], but not from [www.vimeo.com]??? :)))
Re: Module: BB Code Video
August 09, 2007 03:08PM
See if 1.0.6 fixes this for you. I made some changes, but are too busy currently to really test it out. I think it should be okay though. Let me know if I am wrong ;)


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: BB Code Video
August 09, 2007 04:51PM
Quote
mmakaay
See if 1.0.6 fixes this for you. I made some changes, but are too busy currently to really test it out. I think it should be okay though. Let me know if I am wrong ;)

that seems to have solved the problem. the javascript is being included now.

Thank you very much for the quick fix.



Edited 1 time(s). Last edit at 08/09/2007 04:52PM by freedman.
Re: Module: BB Code Video
August 09, 2007 05:02PM
That fix actually was for supporting vimeo.com and www.vimeo.com. But at the same time I did add an .htaccess file to the distro. Since it's working for you now, I think I was right all along and your server simply did not allow you to load the javascript library from the module's directory. Good that it is working now.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: BB Code Video
August 09, 2007 08:48PM
Quote
mmakaay
That fix actually was for supporting vimeo.com and www.vimeo.com. But at the same time I did add an .htaccess file to the distro. Since it's working for you now, I think I was right all along and your server simply did not allow you to load the javascript library from the module's directory. Good that it is working now.

I swear to god, the library wasn't in the page code initially.. I did a view source and search for the js library, and it just wasn't there.. I promise.
Re: Module: BB Code Video
August 09, 2007 10:43PM
Well, then it must have been (looks up BOFH excuse of the day) solar flares interrupting the disk I/O =)


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: BB Code Video
August 12, 2014 05:41AM
Ah, I'd like to start off by saying how much I love phorum. ^//^ I was needing a super-light weight phorum as I run it on a raspberry pi (and soon cluster) and this just fit's the bill perfectly.. so yes, thank you for all your hard work. :D

Anyways, I just wanted to let you know that Youtube now automatically redirects users to us https instead of http, so it has broken the mod a bit when it comes to using plain urls.. To fix this though I just modified the youtube search lines (lines 12-18 and 32-42) to have the regex...
Language: PHP
$search[] = "/\[video\]http.*:\/\/ . . .
instead of
Language: PHP
$search[] = "/\[video\]http:\/\/ . . .
..so that it will match either plain http urls or https urls. I tried using the regex $search[] = "/[video/](http|https):\/\/ . . . initially to explicitly allow http or https, but it just broke the mod.. But then again, my regex-fu isn't as strong as I'd like, so I probably just messed the or statement up. lol



Edited 4 time(s). Last edit at 08/12/2014 06:16AM by hackeritalics.
Sorry, only registered users may post in this forum.

Click here to login