in reply to Checking user's IP....

You could log the IP addresses to a file and then search it. If you're running your site with a database you could log them to a table.
$address=$ENV{REMOTE_ADDR}; open FILE, "<logaddresses.dat"; my $addresses; { local $/=undef; $addresses=<FILE>; } close FILE; if($addresses=~/\Q$address/){ print "You already voted\n"; } else{ open FILE, ">>logaddresses.dat"; print " $address\n"; close FILE; # update poll; } #display results;
if you want code for a database solution let me know

Replies are listed 'Best First'.
Re: RE: Checking user's IP....
by Anonymous Monk on Sep 13, 2001 at 19:36 UTC
    I had the code checking user IP but I need the code to search IP address and if IP address is found, redirect to the found IP address by connecting open connection to telnet using the found IP address. I would appreciate if you could help me with this code. Thanks