<[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
>
> Hi,
>
> This is really wierd - I can't post this msg to the list!  The Test went
> through fine, but every time I try and post the msg below, it just
> "disappears".
>
> Anyone guess why?
>
> Anyone know the answer?!!
>
> cheers,
>
> David
>
>
> Subject: Get Tomcat's port in startup servlet
>
> Body:
> Hi,
>
> I have a servlet which runs on startup.
>
> Within it, I need to get the port number that tomcat is using.
>
> Does anyone know the best way to do this?

Strictly speaking, you want request.getLocalPort().  However, usually you 
want request.getServerPort() instead.

>
> cheers,
>
> David
>
>
>
>
> |---------+---------------------------->
> |         |           "David Hay"      |
> |         |           <[EMAIL PROTECTED]|
> |         |           l.com>           |
> |         |                            |
> |         |           06/24/2005 09:19 |
> |         |           AM               |
> |         |           Please respond to|
> |         |           "Tomcat Users    |
> |         |           List"            |
> |         |                            |
> |---------+---------------------------->
> 
>  
> >---------------------------------------------------------------------------------------------------------------|
>  | 
> |
>  |       To:       tomcat-user@jakarta.apache.org 
> |
>  |       cc: 
> |
>  |       Subject:  Test - please ignore! 
> |
> 
>  
> >---------------------------------------------------------------------------------------------------------------|
>
>
>
>
> testing
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED] 




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to