Re: client ip in bodyTop_NavigationMain

Alois Blasbichler <[email protected]>
Newsgroups gmane.comp.cms.zms.devel
Message-ID <[email protected]>
Thank you for the answer - so i see an ip-adress in my webpage.
But mostly this is the adress of my apache/proxy  - like you write .

Is it not possible to show the client ip ? - Maybe i have to use javascript or embedd a php-script ?

Maybe someone can give me a working example.

By
luis




________________________________
From: Sebastian Tänzer <[email protected]>
To: [email protected]
Sent: Thu, November 12, 2009 2:24:46 PM
Subject: Re: [zms-developers] client ip in bodyTop_NavigationMain

Hello Luis,

inside one of your templates (standard_html_header for example) add this:
<pre><dtml-var REQUEST></pre>
This should show you the available "variables".

You can "get" these by using the REQUEST object like this:
<dtml-var "REQUEST['REMOTE_ADDR']">

In most cases this should give you the IP of the clients internet connection.
As far as I know you can't show the clients local IP (ie. the IP of the workstation).

Sincerely,
Sebastian Tänzer

[tm] taenzer media
online media agency

Kekuléstr. 39
53115 Bonn
Germany

Tel      +49-228-304134-0
Fax    +49-228-304134-99
Mobil  +49-174-333-7001

E-Mail [email protected]
WWW  http://www.taenzer.me

Am 12.11.2009 um 14:18 schrieb Alois Blasbichler:

> 
> Hello list
>  
> I am new to this list (but only with this account - i used this list before with a other e-mail-address)
> 
> I have a short (i hope) question:
>  I want that on the top of my web-Site ther was shown the ip-adress of
>  the client who visit my site  (is it a intranet-site and the ip is
>  for us very usefull)
> 
>  I have seen there is a varibale remote_addr.
>  Can you please give mne the code how to show this varible in my site.
> 
> 
>  Thank you
>  luis
> 
> 
> 



------------------------------------

Yahoo! Groups Links
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.