Questions tagged [httphandler]

HttpHandlers are classes that implement the IHttpHandler and IHttpAsyncHandler interfaces. This section describes how to create and register HttpHandlers and provides examples of a synchronous handler, an asynchronous handler, and a handler factory.

ASP.NET Request Processing

Introduces ASP.NET handling of HTTP requests.

Creating HttpHandlers

Discusses the creation of synchronous and asynchronous HttpHandlers.

Registering HttpHandlers

Describes how ASP.NET is configured to call an HttpHandler.

HttpHandler Factory

Describes how to generate a new handler instance for each HTTP request.

Related Sections

HTTP Runtime Support

Provides an overview of how to use IHttpModule and IHttpHandler interfaces. 

HttpModules

Provides an overview of HttpModules. 
1249 questions
0
votes
1 answer

Detect HTTPHandler Start

Is there a way to detect if a httphandler has started transmitting? I'm trying to do large dynamic Excel Exports (in html table format). I can do this, but there's a long delay from the httphandler getting the message and starting the download. I…
user1382306
0
votes
2 answers

HttpHandler write to redirected page before sending file

I can never seem to find any docs on .net, and the official ones (when they're correct) are a hopeless maze. I redirect a user with jQuery to an HttpHandler on a new page where I build and send an html table (and call it an excel file) on the fly. …
user1382306
0
votes
1 answer

Write as building table in HttpHandler?

I have to export very large files as an "excel export". Since .NET can't export excel files, I went with simple html tables. It works fine, but it's slow. Is it possible to context.response.write each line as they're being created instead of…
user1382306
0
votes
1 answer

Splitting a .ashx Generic Handler into Partial Classes

I have been trying to split my generic handler into multiple files. It is designed to receive all commands and all request types from a page, so I have it processing GET, POST, PUT, and DELETE with multiple commands for each request. Thus, there is…
HenryZhang
  • 1,318
  • 8
  • 11
0
votes
2 answers

HttpHandler not working on site using different port

I wrote a tiny HttpHandler, which works beautifully on my machine. However, once it was deployed to our staging server, requesting it gave an 404. I usually prefer configuring HttpHandlers in web.config, but this apparently didn’t work on the…
Jakob Gade
  • 12,319
  • 15
  • 70
  • 118
0
votes
1 answer

Pass Array via Query String to HttpHandler

I've looked all over, and I can't find a solution for this. Correction: I find solutions, but they (I can't make them) work. I'm passing an array to an HttpHandler via the query string. I've read that you read it this way: Sub ProcessRequest(ByVal…
user1382306
0
votes
2 answers

Intercept http request for the files on file server

http://myfileserver/images/car/chevrolet.gif I have this file server holding the files such as images, doc files etc. Now i want to intercept the http request and based on the file extension i want perform some action such as redirection to some…
Karan
  • 3,265
  • 9
  • 54
  • 82
0
votes
1 answer

Doing an HTTP Post from PHP to an HTTP Handler

So the title is self descriptive. Here is my php code function do_post_request($url, $data, $optional_headers = null) { $url = 'http://localhost:1181/WebSite1/PostHandler.ashx'; $data = array( 'fprm' => 1, 'sprm'=> 2, 'tprm'=>3 …
shabby
  • 3,002
  • 3
  • 39
  • 59
0
votes
1 answer

asp.net with autofac - all controls on webform are null

I'm using autofac with asp.net. In Global.asax I register all my web pages: AssertNotBuilt(); // Register Web Pages m_builder.RegisterAssemblyTypes(typeof(AboutPage).Assembly) .Where(t => t.GetInterfaces().Contains(typeof(IHttpHandler))) …
Greg Oks
  • 2,700
  • 4
  • 35
  • 41
0
votes
1 answer

asp.net url rewriting dynamically using httphandler/httpmodule

I have an asp.net application and I need to do the following: Assume that i have a page called page1.aspx, what i need is that: when the user requests page1.aspx?id=1 to be redirected to http://myapp/books when the user requests page1.aspx?id=2 to…
Alex
  • 5,971
  • 11
  • 42
  • 80
0
votes
1 answer

captcha handler storing value in session outdating

I'm stuck while experimenting with captcha handler in asp.net, any help would be appreciated. Imagine we have such a handler: public void ProcessRequest(HttpContext context) { var text = generateText(); using (var image =…
mumu2
  • 661
  • 1
  • 5
  • 15
0
votes
1 answer

ASHX Image Handler randomly showing/hiding images

I built the ASHX Image Handler which extracts the Images stored in the SQL Server. It works beautifully, if I show the image separately. But If I try to show them in the Grid and show many pictures simultaneously, some of the pictures are not…
TTCG
  • 8,805
  • 31
  • 93
  • 141
0
votes
2 answers

Endless loop when calling an HttpHandler

I’ve built an HttpHandler (ASHX) that sits in my web project. I have a test page that invokes the Handler and the Handler returns what it is supposed to. However, as soon as the return is done it gets invoked again. And again, and again, and…
Keith Barrows
  • 24,802
  • 26
  • 88
  • 134
0
votes
1 answer

ASP.NET adding Authentication to Report Handler

I've got a Active Reports Handler configured on my website so that i can open the Report directly over a link e.g. http://localhost/Report.rdlx?OutputFormat=pdf The problem now of course is that there is no authentication so that everyone can call…
0
votes
1 answer

How to see if IIS is actually sending requests to ASP.Net?

I have setup in the script maps for a site in the IIS metabase a wildcard mapping to ASP.Net for a particular directory within the site. I have a handler setup in the web.config which should be handling requests for said path and it should never…
YonahW
  • 15,790
  • 8
  • 42
  • 46