Jump to content

"Secret" download URLs


ecopetition

Recommended Posts

Hi,

 

I'm looking to make a file have a secret URL with PHP. I want it so that the URL www.x.com/files/file.zip is shown as www.x.com/download.php?file_id=1 (or otherwise). The filename is stored in a database, is assigned a unique ID, and the actual file is stored in a folder under and encrypted name (random MD5 hash).

 

I tried searching this but only came up with one script which wasn't suitable.

 

Any ideas?

 

Thank you.

Link to comment
Share on other sites

Notice:Undefined Index ........

 

PHP Error reporting is set to E_ALL or E_NOTICE.

 

 

ini_set('error_reporting', E_ERROR);

 

Drop that in your page(s) and it will take error_reporting to a less strict level. Or on the other hand, you can fix the errors by initiating the variables first.

 

Nate

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.