-
Logging IP addresses
OK, I am trying to write a CGI script that records the IP address of the people that run it. I am doing this under SunOS 5.8. I have tried using cgicc, but I have a 9 MB quota and it comes out to about 25 MB compiled. Is there functionality built into some library of g++ to log the ip?
-
wouldn't this go under GD scince its CGI?
-
no, you can write CGI scripts in C++ :D
-
25 MB??? I always thought it would only amount to less than 200 kB :confused: Even my C++ TCP/IP client program hasn't reached over 100 kB. You should use Perl scripts instead -- it would be a lot smaller :)
-
That was just teh size of the compiled library, but nevermind. Someone was kind enough to point out that the address of the client is stored in the env. variable REMOTE_ADDR, so no need for the library I was try to use in this instance.