Thread: How to get IP address in C?

  1. #1
    Registered User
    Join Date
    May 2002

    Question How to get IP address in C?

    Is there any way to retrieve local PC IP address of user in C prg.?
    I would like to track the users on our website, also to block if someone tries to flood messages in the forum.
    All I need is to get his IP address when he logs in the forum. Is there any function to retrive IP address of user into C prg.?

    Any help would be appreciated. Thans in advance.

  2. #2
    Im back! shaik786's Avatar
    Join Date
    Jun 2002
    Bangalore, India
    Doesn't your web server LOG this? And how is "C" involed here???

  3. #3


    i agree web servers log ip's there would be no reason to do that in c,... unless your makeing a trojan virus... or something like that

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Linux raw socket programming
    By cnb in forum Networking/Device Communication
    Replies: 17
    Last Post: 11-08-2010, 08:56 AM
  2. What does this do (Windows API)?
    By EVOEx in forum Windows Programming
    Replies: 4
    Last Post: 12-19-2008, 10:48 AM
  3. DX - CreateDevice - D3DERR_INVALIDCALL
    By Tonto in forum Game Programming
    Replies: 3
    Last Post: 12-01-2006, 07:17 PM
  4. Identify dynamic IP address of network device
    By BobS0327 in forum Tech Board
    Replies: 2
    Last Post: 02-21-2006, 01:49 PM