Author |
Topic |
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
Posted - 20 February 2006 : 04:17:43
|
I think I've found the cause of the problems with this mod outside the oxle code ; on oxle.com topic.asp includes inc_func_posting.asp ; inc_func_posting.asp includes the cleancode function. In the functions, this function is called as shown below:
strCodeText = Trim(CleanCode(strCodeText)) If you comment out this line from the various functions, it will work. However, this may provide a possible 'security risk' with respect to cross site scripting. Therefore, you should change this: Replace all instances of this code:
strCodeText = Trim(CleanCode(strCodeText))
'strip all possible javascript code from between the tags
if instr(strCodeText,",") > 0 or _
instr(strCodeText,")") >0 or _
instr(strCodeText,"(") >0 or _
instr(strCodeText,";") >0 or _
instr(strCodeText,"""") >0 or _
instr(strCodeText,",") >0 then
strCodeText = "illegal"
end if
with this code:
'strCodeText = Trim(CleanCode(strCodeText))
'strip all possible javascript code from between the tags
if instr(strCodeText,",") > 0 or _
instr(strCodeText,")") >0 or _
instr(strCodeText,"(") >0 or _
instr(strCodeText,";") >0 or _
instr(strCodeText,"""") >0 or _
instr(strCodeText,"<") >0 or _
instr(strCodeText,">") >0 or _
instr(strCodeText,"[") >0 or _
instr(strCodeText,"]") >0 or _
instr(strCodeText,",") >0 then
strCodeText = "illegal"
end if
I've also updated the original instructions, so you can also copy the new functions from there.< |
portfolio - linkshrinker - oxle - twitter |
Edited by - MarcelG on 20 February 2006 04:35:36 |
|
|
ILLHILL
Junior Member
Netherlands
341 Posts |
Posted - 20 February 2006 : 13:23:52
|
I got it to work. I had to add 'end if' underneath 'strCodeText = "illegal"' in the 'Function ReplaceFlashTags(fString)' part, near the end of the function.
This Mod is beautiful!
Greets & much thanks!
Dominic < |
CLPPR.com - All The News Only Seconds Away |
|
|
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
Posted - 20 February 2006 : 13:55:07
|
Thanks for that feedback! I'll update the instructions once again....(I guess I'll have to be more accurate, even/especially on a monday morning )< |
portfolio - linkshrinker - oxle - twitter |
|
|
weeweeslap
Senior Member
USA
1077 Posts |
Posted - 20 February 2006 : 18:18:53
|
hmmm I will reinstall it and add such code and see if it works then.< |
coaster crazy |
|
|
weeweeslap
Senior Member
USA
1077 Posts |
Posted - 21 February 2006 : 03:13:10
|
it works, thanks!< |
coaster crazy |
|
|
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
|
AnonJr
Moderator
United States
5768 Posts |
Posted - 21 February 2006 : 08:45:27
|
And this code is set for semi-standard forums?
I may have to give it a shot this weekend. < |
|
|
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
|
AnonJr
Moderator
United States
5768 Posts |
Posted - 21 February 2006 : 13:17:23
|
'Nother item on the ole "to-do" for the weekend. < |
|
|
Karel Bata
Junior Member
United Kingdom
122 Posts |
Posted - 22 February 2006 : 09:51:38
|
Hi guys,
Sorry to butt in.
What you're doing here is exactly what I'm looking for. I'm running a forum at http://ukfilm.forumco.com/ (currently semi-closed down, but due for a re-launch) aimed at UK film-makers, and this thing of embedding a video is exactly what I'd like to do on a sister forum I want to set up.
For all kinds of reasons I don't want to run a forum off my own server, but am happy (sort of) to pay a forum provider that will give me what I want. If any of you guys can provide that, or know where else I can go, I'd be very grateful.
(In fact, I'd say that someone offering a forum service with this functionality would do very well indeed!) < |
|
|
|
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
|
Karel Bata
Junior Member
United Kingdom
122 Posts |
Posted - 22 February 2006 : 18:35:48
|
I don't get the impression that I can customise it as much as I did Forumco's to get the one I have at http://ukfilm.forumco.com/ Or am I wrong?
Very much to my surprise the video doesn't have to load afresh when I've rebooted the PC and accessed the thread again. So it's stored in my temp cache? That's cool. And even though Quicktime is set for 'fast start' the file only downloads when you hit play? Cool too.
What happens if you try playing a file outside of the size you've set? It looks bad? Is it not possible to have parameters that will resize the picture window to whatever's being downloaded? Or centre it within a big window?< |
Edited by - Karel Bata on 22 February 2006 19:34:14 |
|
|
Podge
Support Moderator
Ireland
3775 Posts |
Posted - 22 February 2006 : 19:39:59
|
The html can be setup so that the players like Windows Media Player & Quicktime don't start buffering until the play button pressed. Marcel's mod allows a user to post a few different formats, they don't have to post in all four formats but they could if they wanted to.
Does the copyright issues not bother you (being a film maker) ? From a hosts point of view (and the abuse that could arise) it could be a lot of trouble. I have considered a few options myself, mainly integrating http://video.google.com or http://www.youtube.com as they both provide an easy (relatively) way of posting video. As they host the video, audio, etc. copyright and bandwidth issues are their responsibility.
Marcel, it should be easy enough to add YouTube if you're interested, all you have to do is capture a querystring. Google will be a lot harder though.< |
Podge.
The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)
My Mods: CAPTCHA Mod | GateKeeper Mod Tutorial: Enable subscriptions on your board
Warning: The post above or below may contain nuts. |
|
|
MarcelG
Retired Support Moderator
Netherlands
2625 Posts |
Posted - 23 February 2006 : 02:28:59
|
quote: Originally posted by Karel Bata
I don't get the impression that I can customise it as much as I did Forumco's to get the one I have at http://ukfilm.forumco.com/ Or am I wrong?
Nope, you're right. There's no customising, except for the logo.
quote: Originally posted by Karel Bata
Very much to my surprise the video doesn't have to load afresh when I've rebooted the PC and accessed the thread again. So it's stored in my temp cache? That's cool. And even though Quicktime is set for 'fast start' the file only downloads when you hit play? Cool too.
Yep. Please realize that it's just the <embed> tag, so normal HTML. No actual streaming of the video from your forum/site, if the file isn't stored on your site.
quote: What happens if you try playing a file outside of the size you've set? It looks bad? Is it not possible to have parameters that will resize the picture window to whatever's being downloaded? Or centre it within a big window?
That depends a bit on the platform/player you're using, and the codec used. For Flash, you won't see any quality decrease.
I've also got the code that allows admins to post specific size parameters for the video's ; see http://oxle.com/topic.asp?tid=3392&SearchTerms=ewmv#31697
quote: Originally posted by Podge
Marcel, it should be easy enough to add YouTube if you're interested, all you have to do is capture a querystring. Google will be a lot harder though.
If you've got the trick for YourTube, I'm all ears. GoogleVideo is actually much easier than you might think. It's just flash, and since a couple of weeks they've got the 'put on your site' option, which provides the source-url for the embed-tag. Being flash, [flash][/flash] around that GoogleVideo URL works as a charm. I guess the same applies to YourTube, but they don't have the 'put on your site' option yet.
BTW ; I modded my linkshrinker to auto-create a videoplayer URL for GoogleVideo-'put on my site'-urls. Very handy.< |
portfolio - linkshrinker - oxle - twitter |
Edited by - MarcelG on 23 February 2006 02:34:51 |
|
|
Podge
Support Moderator
Ireland
3775 Posts |
Posted - 23 February 2006 : 06:32:55
|
I'm aware of the "Put video on site" Google code. I managed to insert a video on a post and it worked after a bit of fiddling. Ideally a user would just copy the code into a post but this presents security issues which should be checked (ideally) both client and server side. The Google code itself is too complicated to expect a user to extract the correct bit.
For youTube, the best way is to take the permalink not the code they provide. Then use a simple regex to extract the querystring and then build the code from that. It means that the user just has to enter one link and the correct code gets inserted.
Forgot to say earlier that this mod rocks bigtime. I've been meaning to contact you about something else in the last few weeks but have been too busy.< |
Podge.
The Hunger Site - Click to donate free food | My Blog | Snitz 3.4.05 AutoInstall (Beta!)
My Mods: CAPTCHA Mod | GateKeeper Mod Tutorial: Enable subscriptions on your board
Warning: The post above or below may contain nuts. |
|
|
Topic |
|