Forum Moderators: coopster
$domain = gethostbyname($REMOTE_ADDR);
And use that to prevent the person from uploading again, by checking the ip address of the visitor against the database list you have in your DB.
I am not sure which IP Address you get from the above line though. Someone will let us know the right syntax if the above is not working for you.
Habtom
$ip = $_SERVER['REMOTE_ADDR'];
Restricting a user by IP is definitely the way to go, restricting a user by Session would be very easy to get around (just start a new browser instance).
You might run into problems using IP address as the only way of determining users, as certain ISP's (AOL springs to mind) use Proxy Servers which offer up the same IP address for multiple users so you could be inadvertently restricting users from uploading.
If you have any sort of login process before the user is allowed to upload, I would try and modify this to record when a user uploads something as it will likely be much more accurate.
[edited by: Sagaris at 10:57 am (utc) on June 6, 2007]
Update - Disregard this as moroose has just stated he doesn't have an email col!
[edited by: Sagaris at 12:44 pm (utc) on June 6, 2007]