473,782 Members | 2,439 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Request.ServerV ariables("HTTP_ HOST")

JT
if i am using https, will this work the same as if i were
using http?

Request.ServerV ariables("HTTP_ HOST")

returns www.mywebsite.net for http.

what about https?????
thanks much

jt
Jul 19 '05 #1
4 18827
Why not just try it and see?

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
JT <an*******@disc ussions.microso ft.com> wrote in message
news:13******** *************** ******@phx.gbl. ..
if i am using https, will this work the same as if i were
using http?

Request.ServerV ariables("HTTP_ HOST")

returns www.mywebsite.net for http.

what about https?????
thanks much

jt

Jul 19 '05 #2
JT
because i haven't yet setup https on my webserver... smarty

-----Original Message-----
Why not just try it and see?

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
JT <an*******@disc ussions.microso ft.com> wrote in message
news:13******* *************** *******@phx.gbl ...
if i am using https, will this work the same as if i were using http?

Request.ServerV ariables("HTTP_ HOST")

returns www.mywebsite.net for http.

what about https?????
thanks much

jt

.

Jul 19 '05 #3
hehe, good reason ;o)

Unfortunately, I've not got it on mine either, so can't tell you either way
:o\, though, from what my host tells me, if it's a secure site, the
HTTP_HOST will not be passed onto the referring page.

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
JT <an*******@disc ussions.microso ft.com> wrote in message
news:12******** *************** ******@phx.gbl. ..
because i haven't yet setup https on my webserver... smarty

-----Original Message-----
Why not just try it and see?

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
JT <an*******@disc ussions.microso ft.com> wrote in message
news:13******* *************** *******@phx.gbl ...
if i am using https, will this work the same as if i were using http?

Request.ServerV ariables("HTTP_ HOST")

returns www.mywebsite.net for http.

what about https?????
thanks much

jt

.

Jul 19 '05 #4
It returns the same thing. Note that this variable is not reliable, in that
a person can make that variable be whatever he wants it to be. Example:
yourpage.asp:
<%
Response.Write Request.ServerV ariables("HTTP_ HOST") & " or " &
Request.ServerV ariables("SERVE R_NAME")
%>

Load that page and see the results. Then, open a command prompt (cmd.exe)
and enter this:

(Where xxx.xxx.xxx.xxx is your site's IP address)

echo xxx.xxx.xxx.xxx bogus>>%windir% \system32\drive rs\etc\hosts

Now load http://bogus/yourpage.asp in your browser.
--

Ray at home
Microsoft ASP MVP
"JT" <an*******@disc ussions.microso ft.com> wrote in message
news:12******** *************** ******@phx.gbl. ..
because i haven't yet setup https on my webserver... smarty

-----Original Message-----
Why not just try it and see?

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

Disclaimer:
I know I'm probably wrong, I just like taking part ;o)
JT <an*******@disc ussions.microso ft.com> wrote in message
news:13******* *************** *******@phx.gbl ...
if i am using https, will this work the same as if i were using http?

Request.ServerV ariables("HTTP_ HOST")

returns www.mywebsite.net for http.

what about https?????
thanks much

jt

.

Jul 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
13426
by: David D. | last post by:
Does the file extension matter when including a JavaScript file in an HTML page? Normally, one would include a JavaScript file in an HTML page using <script src="foo.JS" type="text/javascript"> However, I have found that I can use an alternate file extension, such as <script src="foo.HTML" type="text/javascript"> It works fine with my IE 6 and Mozilla. Will it work with other browsers?
2
5024
by: Trapulo | last post by:
I read Context.Request.ServerVariables("HTTP_HOST") from an asp.net page, but I've the problem that it returns always "localhost". I've tried to call the web site as http://server/site (server as netbios over tcp, not dns... in this net there isn't a dns ) http://ip/site from a remote pc, but nothing. I read always localhost. I've tried to stop default web site and create a new site pointing to my
6
4902
by: scottyman | last post by:
I can't make this script work properly. I've gone as far as I can with it and the rest is out of my ability. I can do some html editing but I'm lost in the Java world. The script at the bottom of the html page controls the form fields that are required. It doesn't function like it's supposed to and I can leave all the fields blank and it still submits the form. Also I can't get it to transfer the file in the upload section. The file name...
2
12528
by: E L | last post by:
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? *** Sent via Developersdex http://www.developersdex.com ***
4
3290
by: k3pp0 | last post by:
Hey. I've got a very basic newbie question, I hope you can understand me. Sorry for asking it, first of all. I see a lot of sites (e.g. communities) with a url-structure like this: example.com/users/paul (displaying the user profile of "paul") or example.com/pictures/landscapes/13 (displaying pictures from the category "landscapes", page 13). These are just examples, I hope I didn't confuse you.
1
3936
by: news.microsoft.com | last post by:
I am getting the following error on the return from a function call.It specically happens on the assignment of the return value from the function call. No error happens inside the function. The function is returning an Integer with a value of 1. Err.number =5 Err.Description=Operation is not supported on this platform. Err.Source=System.Web Anyone ever seen this error or can explain why I am getting this? Thanks,
0
9639
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9479
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10146
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10080
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7492
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6733
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5378
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5509
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4043
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.