WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The basic of what I need;

A public page where the visitor have to fill out a form in order to be able to download a large file (the one and the same file for all downloads/users). The file should only be available trough something like a temporary url for a specific amount of time from when the form was submitted. In other words, time limited access to the file for a specific user.

To create and setup the form is no problem, but making the file accessible for a limited amount of time to the user whom submitted the form is a completely different story. I have no good ideas on how to create time limited access. Don't know where to start.

Any ideas on how to create this with WordPress? Plugin suggestions are welcome too.

share|improve this question
up vote 0 down vote accepted

a simple way would be to set a cookie with a timestamp when they submit the form, then check for the cookie and valid timestamp when they hit the url to download the file.

a more complicated process would be to generate a unique url key for each user, put that in a db table with a timestamp, then look up the url, check the time and then delete when they hit it for download.

share|improve this answer
Thanks for your answer. I think I'll go with cookies. – EyesX Apr 27 '11 at 14:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.