PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WEBDEV 2024 → Help with BrowserIPAddress()
Help with BrowserIPAddress()
Débuté par Luis García, 01 sep. 2017 17:43 - 2 réponses
Membre enregistré
11 messages
Posté le 01 septembre 2017 - 17:43
Hi,

I intent to use BrowserIPAddress() to retrieve the web IP address of the users connected to my WebDev site. I was hoping to get something like the www.whatsmyip.org result (xxx.xxx.xxx.xxx), but instead I only get this:






Maybe this is normal since I'm testing on my local computer, but I wanted to make sure that when this goes on production the results are what I expect. If this is the case, is there a way I could test the "actual" result?

If not, please tell me what's wrong in my code. Perhaps I should use another function.

By the way, the documentation states:

<Result>: Character string

IP address of the computer of the Web user:
•in IPv4 format: xxx.xxx.xxx.xxx. For example: 195.196.100.1
•in IPv6 format: xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx

How can I choose the format I want the result?

Thank you.
Message modifié, 01 septembre 2017 - 17:47
Posté le 01 septembre 2017 - 20:09
Hi,


I intent to use BrowserIPAddress() to retrieve the web IP address of the
users connected to my WebDev site. I was hoping to get something like
the www.whatsmyip.org result (xxx.xxx.xxx.xxx), but instead I only get
this:







Maybe this is normal since I'm testing on my local computer, but I
wanted to make sure that when this goes on production the results are


It is normal as you don't have any external IP address when testing
locally (you don't even need internet access).

what I expect. If this is the case, is there a way I could test the
"actual" result?


You need to deploy to a server, it's the only way. Several hosting
provider are offering free test accounts just for that (Kalanda.net, by
example)

If not, please tell me what's wrong in my code. Perhaps I should use
another function.

By the way, the documentation states:
<Result>: Character string

IP address of the computer of the Web user:
•in IPv4 format: xxx.xxx.xxx.xxx. For example: 195.196.100.1
•in IPv6 format: xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx

> How can I choose the format I want the result?
>

AFAIK, you can't, it depends of the settings of the whole string (from
the client computer to each of the servers your communication is going
through)

Up till now, I don't think I have ever received an IPv6 format address
with that function.
> Thank you.

best regards

--
Fabrice Harari
International WinDev, WebDev and WinDev mobile Consulting

Ready for you: WXShowroom.com, WXReplication (open source) and now WXEDM
(open source)

More information on http://www.fabriceharari.com
Membre enregistré
11 messages
Posté le 04 septembre 2017 - 10:11
Thank you very much!!!