0
pilotdave

SkydivingMovies.com Guest Passes

Recommended Posts

Ever want your buddies to check out a video on SkydivingMovies.com but those bastards are too lazy to register? Well, now you can give them a Guest Pass. Just go to the video you want to share and hit "Create Guest Pass." This creates a special page where that video can be downloaded up to 50 times. You can send the link to your friends, they can check it out, and once the 50 downloads are used, well, that's it.

Some people used to cheat and send out direct download links to files on the site. I don't like that. It turns the site into just a big online hard drive. Well I closed that little security hole at 2am this morning, with a stroke of brilliance... or something. So I figured I'd give another option.

BTW, it's still in testing so let me know if you find any funny behavior.

So what do you think? Think you'll use it? Think 50 downloads is a good number? Anything else?

Dave

Share this post


Link to post
Share on other sites
Sounds cool!

One feature request, if I may. Right-clicking on a file, then selecting Save As leaves me with a dialog box in which the suggested file name is "pafiledb.php". I then need to overwrite it with the proper name. Validated on WinXP with Firefox 1.5b1, and IE 5.5, and on Win2K with Firefox 1.06 and IE-something-or-other.

Is there any chance you could do some fancy stuff so that the real filename appears? A URL of the following form would work:

http://www.skydivingmovies.com/ver2/download/collison.mov


or

http://www.skydivingmovies.com/ver2/download/collison.mov?my_other_vars


You could probably even use URL rewriting in Apache to do:

http://www.skydivingmovies.com/ver2/collision.mov?action=file&id=2706


...just replacing the reference to pafiledb.php with the name of the file being downloaded. It'd make downloading files significantly easier.

Thanks for providing a wonderful resource!

Share this post


Link to post
Share on other sites
For me, it works fine in IE but not in firefox. I did solve that problem a while ago but it caused a major memory issue... long story, but it caused the server to crash repeatedly. I'll work on it some more... not really sure why it does that but it's probably easily fixable. When my "perfect" download solution turned out to kill the server, I was too pissed to think about it for a while.

BTW, if any REAL web page design geeks can tell me why fpassthru causes the entire contents of the file to be loaded into the server's memory and a solution to it, I can fix this real fast.

Dave

Share this post


Link to post
Share on other sites
You shouldn't need to go near PHP: http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html


Quote

if any REAL web page design geeks can tell me why fpassthru causes the entire contents of the file to be loaded into the server's memory



The docs imply that it's by design:

Quote

Reads to EOF on the given file pointer from the current position and writes the results to the output buffer.

Share this post


Link to post
Share on other sites
Quote

implementing this new Guest Pass feature, I managed to delete the 3 lines of code that make downloads, well, download. I put them back now. OOPS!



lol. I'll have to check out the guest pass thing sometime. thanks dave!B|

Where is my fizzy-lifting drink?

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

0