Request.ServerVariables("SERVER_NAME") is only returning IP

E

E L

We have the Request.ServerVariables("SERVER_NAME") used in a classic ASP
page using IIS 6.

It used to return our website name: www.xxx.name.this when using IIS 5,
now it is returning the IP address when we type the full www. url.

How can I fix this behavior?
 
E

Evertjan.

E L wrote on 28 feb 2007 in microsoft.public.inetserver.asp.general:
We have the Request.ServerVariables("SERVER_NAME") used in a classic ASP
page using IIS 6.

It used to return our website name: www.xxx.name.this when using IIS 5,
now it is returning the IP address when we type the full www. url.

Are you sure?

Both SERVER_NAME and HTTP_HOST return the server URL here under IIS6.
 
M

Mark J. McGinty

E L said:
We have the Request.ServerVariables("SERVER_NAME") used in a classic ASP
page using IIS 6.

It used to return our website name: www.xxx.name.this when using IIS 5,
now it is returning the IP address when we type the full www. url.

How can I fix this behavior?

I seem to recall that you only get the DNS name if "host headers" are
defined for the virtual site... so maybe a difference in configuration?


-Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,239
Members
46,827
Latest member
DMUK_Beginner

Latest Threads

Top