Fork me on GitHub

php Coding  Bottom

  • Hi. I need a simple code to show visitors or user's ip when they sign the guestbook.

    Thank you!





    edited by: jabbere, Nov 28, 2006 - 12:33 AM
  • Old-style PHP: getenv("REMOTE_ADDR")
    New-style PHP: $_SERVER['REMOTE_ADDR']

    And to get the hostname of your visitor:
    gethostbyaddr($_SERVER['REMOTE_ADDR'])
  • Could you be more specific. I'm not that knowledgeable in PHP. I'd like to add it to a table in one of the templates.

    Your help is greatly appreciated!



    edited by: jabbere, Nov 29, 2006 - 01:21 PM

This list is based on users active over the last 60 minutes.