Help / WLanguage / WLanguage functions / Web-specific functions / Browser functions
  • Accepting (or not) the return address
  • Server IP address
  • Pre-launched sessions
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
Returns the IP address of the client computer connected to the WEBDEV site.
Remark: If the Web user is behind a router, the IP address will be the one of the router.
To get this information from a Webservice, use WebserviceClientIPAddress.
// Returns the IP address of the Web user
sClientAddress is string = BrowserIPAddress()
<Result> = BrowserIPAddress([<Accept return address>])
<Result>: Character string
IP address of the computer of the Web user:
  • in IPv4 format: For example:
  • in IPv6 format: xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx
<Accept return address>: Optional boolean
  • True to accept the initial address specified in the HTTP header,
  • False (default value) to refuse this address. In this last case, the IP address is retrieved in the environment variable (REMOTE_ADDR) defined by the Web server.
By default, the address specified in the HTTP header is rejected for security reasons.
PHP This parameter is not supported.
WEBDEV - Server codeWindowsLinux

Accepting (or not) the return address

The address returned by BrowserIPAddress may not correspond to the user's address (if a non-transparent proxy or a load balancer is used, for example). In this case, BrowserIPAddress returns the IP address of the proxy or load balancer.
If the return address is accepted, BrowserIPAddress tries to read the original address specified in the HTTP headers (most proxies provide the original address in the HTTP headers). However, this address must be used with caution because it is not reliable and can be completely wrong.
  • If the original address is not found or is invalid (too long for example), the "standard" address is sent.
  • In test mode, BrowserIPAddress returns the address of the development computer.

Server IP address

The server IP address is returned by NetIPAddress.

Pre-launched sessions

If your project uses pre-launched sessions, this function must not be used in the project initialization event. This function must be used in the "Initializing the project after connection to the site" event.
Business / UI classification: Neutral code
Component: wd300page.dll
Minimum version required
  • Version 9
Click [Add] to post a comment

Last update: 08/22/2022

Send a report | Local help