In BBj 16.0 and higher, this method returns the port number to which the request was sent. It is the value of the part after ":" in the Host header value, if any, or the server port upon which the client connection was accepted.
Return Value |
Method |
int |
getServerPort() |
None.
an int value of the server port
The example below shows getting the HTTP port of a request within a BBJSP Servlet.
This example demonstrates how this works in a BBJSP web-page
|
This example demonstrates how this works in a BBJSP servlet
|