LassoScript Utility
Basics Browse Detail

[Net->RemoteAddress]

Tag Link [Net->RemoteAddress] Category Networking
Type Member Source Available No
Support Preferred Version 7.0
Change Unchanged Data Source Any
Output Type String Security None
Implementation LCAPI Sets Lasso 8.5, Lasso 8.0, Lasso 7.0

Description

[Net->RemoteAddress] returns the address of the remote machine on the end of a valid connection. This tag only works for TCP connections.

Syntax

<?LassoScript
Variable: 'Connection' = (Net);
$Connection->(Connect: 'www.example.com', 80);
...
Output: $Connection->(RemoteAddress);
?>

Parameters

No Parameters Required.

Examples

To output the local and remote addresses from a connection:

Use the [Net->LocalAddress] and [Net->RemoteAddress] tags. The following example opens a [Net] connection to a remote server and ouptus the local and remote addresses.

[Variable: 'myConnection' = (Net)]
[Var: 'Result' = $myConnection->(Connect: 'www.example.com', 80)]
Local: [$myConnection->LocalAddress]
<br>Remote: [$myConnection->RemoteAddress]

Local: 127.0.0.1
Remote: www.example.com