Mailinglist Archive: opensuse (4626 mails)

< Previous Next >
Re: [opensuse] PHP question
  • From: Anders Norrbring <lists@xxxxxxxxxxxx>
  • Date: Sun, 14 Jan 2007 21:12:56 +0100
  • Message-id: <45AA8EC8.4020506@xxxxxxxxxxxx>
James Hatridge skrev:
Hi all..

My new host will not allow this php command to work:

$cur_ip = $REMOTE_ADDR;

Any ideas how I can program around this?

Thanks,

JIM



Hiya.
Try the "new" way.. $cur_ip = $_SERVER['REMOTE_ADDR'];
See http://www.php.net/manual/en/reserved.variables.php#reserved.variables.server
--

Anders Norrbring
Norrbring Consulting
< Previous Next >
References