Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Usage of CGI environment variables SERVER_NAME and HTTP_HOST by APEX

135285Jul 18 2007 — edited Jul 18 2007
Hi,

I have a question about the usage of the CGI environment variables SERVER_NAME/SERVER_PORT and HTTP_HOST by APEX.

When does it use which CGI environment variables when it is generating absolute URLs.

Based on the following thread about the online help (872204 it seems to use SERVER_NAME/SERVER_PORT. At least for the online help.

But based on my own tests some time ago about the flash charting at the following thread (1927202 I investigated that at least flash charting is using HTTP_HOST to generate an absolute URL.

My question now is what is the logical difference between HTTP_HOST and SERVER_NAME and which of the URLs should be used when I want to generate absolute URLs in my application?

I would tend to use HTTP_HOST because it seems to be more logically. I would see SERVER_NAME more as just the name of the web-server, which doesn't have to be the URL the user enters in case a reverse proxy is used.

Thanks
Patrick
----------------------------------------------------------------------------------------------------
My APEX Blog: http://inside-apex.blogspot.com
The ApexLib Framework: http://apexlib.sourceforge.net
The APEX Builder Plugin: http://sourceforge.net/projects/apexplugin/
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 15 2007
Added on Jul 18 2007
1 comment
699 views