Returns the port number of the server to which you're currently connected.
$port
echo -a $port
Echos the port to your active window.
Take a look at $serverip, $server or $network to receive these information.