The function ap_get_server_port always returns "80", even if other port is defined in configuration file. It has been observed on Solaris 10 and HP-UX.
It could be observed also when show output from mod_info module.
Please post your configuration for the virtual host where this happens. Especially let us know the settings for UseCanonicalPhysicalPort and UseCanonicalName. http://httpd.apache.org/docs/2.2/en/mod/core.html#usecanonicalname http://httpd.apache.org/docs/2.2/en/mod/core.html#usecanonicalphysicalport
Created attachment 20409 [details] My config file related to the issue.
(In reply to comment #2) > Please post your configuration for the virtual host where this happens. > Especially let us know the settings for UseCanonicalPhysicalPort and > UseCanonicalName. > > http://httpd.apache.org/docs/2.2/en/mod/core.html#usecanonicalname > http://httpd.apache.org/docs/2.2/en/mod/core.html#usecanonicalphysicalport OK, I have added the attachement which is designed for my server. UseCanonicalPhysicalPort - it is not set in the configuration file, so default value is used. UseCanonicalName - is set to: On
I guess this is an error in your configuration. Please try the following: Either replace ServerName xxxx.pl.xxxx.com with ServerName xxxx.pl.xxxx.com:8811 or set UseCanonicalPhysicalPort on See also the Note in http://httpd.apache.org/docs/2.2/en/mod/core.html#usecanonicalphysicalport
(In reply to comment #5) It seems that the problem was related to the configuration. I've changed it according to your comment and I got the correct port number.
Thanks a lot for your support and quick answer !