View Full Version : When I offer downloads I usually offer them in a link
12-19-2007, 02:58 PM
When I offer downloads I usually offer them in a link in a anchor in a sub folder. Is it better to put your downloads in a web folder above the web root directory?
Another thing I want is some sort of download manager so that only certain people who log in can download items and only for a certain time, say 3 days.
I know how to do this but I just wanted to know if there is good code out there i can use.
There is a nifty web program called File Manager Pro, out of the UK.. made by Idotcommunications... pretty cool.. it might be a little more than what you are looking for though.
12-21-2007, 09:48 PM
You could upload all of your files in a database as a blob type, and you can just make a little snippet page to download files based on a get method.
./download.php?id=1 would be one file
./download.php?id=2 would be another
you can keep track of how many downloads are made and can be made with php. You can also just use a easy to set up phpmyadmin for your database to upload the files at anytime.
Here's a good way of doing it: http://www.php-mysql-tutorial.com/php-mysql-upload.php
But if you use this page, make sure you change the line in download.php of:
<a href="download.php?id=<?php=$id;?>"><?php=$name;?></a> <br>
<a href="download.php?id=<?php echo $id; ?>"><?php echo $name; ?></a> <br>
12-21-2007, 09:54 PM
impressive understanding, thanks
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.