PC Review


Reply
Thread Tools Rate Thread

Changing Request Headers values

 
 
=?Utf-8?B?SnVzdGluUw==?=
Guest
Posts: n/a
 
      16th Aug 2005
How do I change a value in the request headers?

I need the value Request.Headers.Item("Host") to be changed from localhost
to a domain name, any thoughts?

I know it should be easy to do because ASP.net makes everything easy, but I
can't seem to figure it.

Thanks

I have already tried:
* Creating a IHttpHandler
* Adding a property to global.asax called Request that was not read-only
* Creating a new class that inherits from HttpRequest but the class is
marked as NonInheritable
 
Reply With Quote
 
 
 
 
Andy Fish
Guest
Posts: n/a
 
      16th Aug 2005
It seems a very dodgy thing to want to do, so I'm not surprised it's not
working.

If you can explain why you think you need to do this, maybe someone will
come up with a better solution.

"JustinS" <(E-Mail Removed)> wrote in message
news:7F218F07-F1B1-4ABF-B905-(E-Mail Removed)...
> How do I change a value in the request headers?
>
> I need the value Request.Headers.Item("Host") to be changed from localhost
> to a domain name, any thoughts?
>
> I know it should be easy to do because ASP.net makes everything easy, but
> I
> can't seem to figure it.
>
> Thanks
>
> I have already tried:
> * Creating a IHttpHandler
> * Adding a property to global.asax called Request that was not read-only
> * Creating a new class that inherits from HttpRequest but the class is
> marked as NonInheritable



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Request.Headers.Get Mike J. Microsoft Dot NET 2 27th Apr 2009 05:50 PM
can you still add request headers? =?Utf-8?B?QWRhbQ==?= Microsoft ASP .NET 4 5th Nov 2007 03:55 AM
Changing Request.Form collection values Kobi.Pinhasov@gmail.com Microsoft ASP .NET 3 9th Feb 2006 01:01 PM
altering Request.Headers =?Utf-8?B?QWRhbQ==?= Microsoft ASP .NET 1 20th May 2005 03:50 AM
Re: Web Request Headers Mark Relly Microsoft C# .NET 0 11th Aug 2003 04:28 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:15 AM.