Ritesh,

This one liner code in php will give the ip address
<? echo $REMOTE_ADDR; ?>

But be careful, the returned ip address may be either that of the remote
client or of the proxy through which it is available. Perhaps you are
using the server as the proxy and hence this value.

If you want to see more information,
<? phpinfo(); ?>

This will list out all tonnes of information about your php.
All the items under the Apache section are accessible as variables - as
used in the above example.

regards,
alok sinha

HASH BABA wrote:

> Hii All ,
>
>    I Think My problem is  so simple ,though i can't solve it ,
> becoz i don't know how to program in PHP.
>
> well , Problem is that , My PHP script installed  in  a webserver
> ,I just want that whenever client request for that script,Script
> should return the IP address of client machine.In other word we
> can say that PHP Script should return the IP address of evey
> machine , where it runs.
>
> I use getenv('REMOTE_ADDR'); function , but it returns the IP
> address of server instaed of Client .
>
> well if all of you have understand my problem then help me
> Thanks in advance.
> Ritesh
> ___________________________________________________
> Meet your old school or college friends from
> 1 Million + database...
> Click here to reunite www.batchmates.com/rediff.asp
>
> _______________________________________________
> ilugd mailing list
> [EMAIL PROTECTED]
> http://frodo.hserus.net/mailman/listinfo/ilugd


_______________________________________________
ilugd mailing list
[EMAIL PROTECTED]
http://frodo.hserus.net/mailman/listinfo/ilugd

Reply via email to