Welcome Guest ( Log In | Click here to Register a free account now! )
Welcome to Bleeping Computer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.![]() ![]() |
Jun 30 2009, 10:36 PM
Post
#1
|
|
|
Forum Regular ![]() ![]() ![]() Group: Members Posts: 170 Joined: 1-November 07 Member No.: 166,999 |
I want to start an extra domain on my hosting account when you go to it you can upload images. You upload the image and it gives you a link thats all it needs to do. Like if I uploaded C:\Users\Admin\Pictures\1.jpg It wold give me a random link like: www.freeimagehost blah blah.com/sd45skfh49s Anyone know how to do this? I also want to be able to view images that have been uploaded and delete them if they do not meet my rules, like if they are bad images. I assume this can be done if the images are stored in a folder on the ftp server i can just view them in the folder? |
|
|
|
Jun 30 2009, 10:43 PM
Post
#2
|
|
![]() Hail Groovicus! ![]() ![]() ![]() ![]() ![]() ![]() Group: Site Admin Posts: 7,960 Joined: 5-June 04 From: Centerville, SD Member No.: 689 |
First, how are you going to limit use of bandwidth? I know for a fact that if you start using too much bandwidth, your ISP is going to cut you off, unless of course you agree to additional charges. You might want to check with your ISP and see where that threshold lies, and check into expenses. If everything is cool there, then it is a matter of breaking down the project into small pieces.
-------------------- |
|
|
|
Jul 1 2009, 09:14 AM
Post
#3
|
|
|
Forum Addict ![]() ![]() ![]() ![]() ![]() ![]() Group: BC Advisor Posts: 1,414 Joined: 6-July 08 From: South Garden Member No.: 220,807 |
You need an SQL server like mySQL
whenever someone uploads file, generate random name, rename it and add information of link, filename, tags, time of upload, user who uploaded etc, ip address of user in sql database. When someone accesses the file, it should be looked up in the database and link should be redirected. You can also keep count how many times a file has been viewed and limit bandwidth accordingly. You can delete the file after certain number of days it was uploaded. Its a game of how you utilize SQL. for example someone uploads 1.jpg u generate random unique name bbcder.jpg (checking for duplicates in sql db) put file as hxxp://files.imagehost.com/db1/bbcder.jpg tell user link is hxxp://www.imagehost.com/fetch.php?file=bbcder.jpg .... .... .... PHP and mySQL are perfect for this. But you may also want ASP.net and MS SQL server Edit: neutralized fake links This post has been edited by Romeo29: Jul 1 2009, 09:14 AM -------------------- |
|
|
|
![]() ![]() |
| Lo-Fi Version | Time is now: 21st November 2009 - 07:27 PM |