httphandler

HttpHandler and XML files

Hello, I would like to intercept any request made to the server for XML files. I thought that it might be possible with an HttpHandler. It's coded and it works... on localhost only (?!?!). So, why is it working on localhost only? Here is my web.config <?xml version="1.0" encoding="utf-8"?> <configuration> <system.web> <httpHandle...

internet explorer ashx file problem

My problem is a bit complicated: I am writing in c#, asp.net and using jquery I have a page that sends requests to the server using jquery's ajax method. I have a ashx file (handler) to respond to these request. User can perform several changes on several pages, then use some method that will call the ajax method. My ashx file reads so...

Does ASP.net 1.1 support Generic HttpHandlers ?

I need to get an image from a SQL Server as a byte[], and load it to a WebControl.Image. The only seemingly good way to do it that I found is to implement IHttpHandler and handle the request accordingly. But I'm stuck to using asp.net 1.1. Does it support ashx files? ...

Fake Image using .aspx url to track email views in Outlook, doesn't work!

I have this in my HTML email to track if someone views the email in say Outlook. <img src="http://www.example.com/track.ashx?user=3434" /> but this doesn't seem to work. Should I change my headers in the .ashx to server image headers? (if there are any?) Can this work using this method? I emailed myself with an email, other images ...

ASP.NET 3.5 C# : Combine images in one download

I Would like to know if its possible to combine mulitple images in 1 download. On my homepage I'm showing 12 images which change depending on the country of the user. I notice this takes a lot of time to download for some users and i would like to know if it's possible to combine them into one download with an httphandler (in the way u ...

Errors not being redirected to an Http handler if redirectMode="ResponseRewrite"

I see similar questions, but it looks like there were due to an unrelated issue. in 3.5, I have a custom error handler that logs errors and redirects users. My web.config is set up as such: <httpHandlers> <add path="error.ashx" type="MySite.Tools.WebErrorLogger, MySite.Tools" verb="*"/> </httpHandlers> <cus...

Posting data to a HttpHandler greater then ~29MB gives a 404 error

I am testing a HttpHandler that accepts XML. It works fine when a small amount of data is posted but if I post data larger then approx 29mb, I get a asp.net 404 Error. I am posting to the handler from another handler in the same project and I have tried 2 methods - 1. HttpWebRequest with "POST" 2. WebClient with UploadFile() and UploadD...

VS2010 development web server does not use integrated-mode HTTP handlers/modules

I am developing an ASP.NET MVC 2 web site, targeted for .NET Framework 4.0, using Visual Studio 2010. My web.config contains the following code: <system.webServer> <modules runAllManagedModulesForAllRequests="true"> <add name="XhtmlModule" type="DomenicDenicola.Website.XhtmlModule" /> </modules> <handlers> <...

httpHandler - subfolder issue

Hi, I am trying to redirect my old typepad blog to my new blog (permanent 301 redirect) that runs with wordpress. The new blog will also be on a new server. the old Blog had the following structure: http://subdomain.domain.com/weblog/year/month/what-ever-article.html The new Blog looks like this: http://www.domain.com/Blog/index.php/y...

dynamic image control

I am getting dynamic image in form of byte array. and i want to show that in webpage, preferably ImageControl I am aware of method of creating http handler and getting image stream. but I cant do that here as logic for same is performed somewhere else. Could not get any suitable way to do this. Thank you in advance. ...

Viewstate in a .ashx Handler?

I've got a handler (list.ashx for example) that has a method that retrieves a large dataset, then grabs only the records that will be shown on any given "page" of data. We are allowing the users to do sorting on these results. So, on any given page run, I will be retrieving a dataset that I just got a few seconds/minutes ago, but reord...

Use ASP.Net server control code generation from .ashx

I'm trying to take an existing bunch of code that was previously on a full .aspx page, and do the same stuff in a .ashx handler. The code created an HtmlTable object, added rows and cells to those rows, then added that html table the .aspx's controls collection, then added it to a div that was already on the page. I am trying to keep t...

Does an HttpHandler require an aspnet_isapi.dll mapping

Hi, If I configure (via web.config) an httphandler to handle all .gif requests for a specific folder, is it absolutely essential for me to map .gif requests to aspnet_isapi.dll in IIS? Is there any other way of ensuring that the .gif http request will be handled by aspnet_isapi.dll? I have a server configured where the virtual dir tha...

Creating a HTTP handler for IIS that transparently forwards request to different port?

I have a public web server with the following software installed: IIS7 on port 80 Subversion over apache on port 81 TeamCity over apache on port 82 Unfortunately, both Subversion and TeamCity comes with their own web server installations, and they work flawlessly, so I don't really want to try to move them all to run under IIS, if th...

HTTP Handler error when downloading files - SSL

Ok big problem as this is affecting two projects on our new server. We have a file that is downloaded by users, the files are downloaded using a HTTPHandler. Since moving the site to the server and setting SSL the downloads have stopped working and we get an error message "Unable to download DownloadDocument.ashx" from site". DownloadDoc...

HttpHandler help please

I want to write an HttpHandler to redirect traffic to various webpages on the server. The user will type in http://www.thisissupposedtoberedirected.com/site12 and should be redirected to the appropiate site, in this example site version 1.2 I know how to program in ASP.NET and C# but I don't seem to grab the finer detail about website m...

Can' get couchdb external http handlers to work.

following the instructions here http://wiki.apache.org/couchdb/ExternalProcesses this is what I get { * error: "{{badarg,[{erlang,port_command, [#Port<0.2056>, [123, [34,<<"info">>,34], 58, [123, [34,"db_name",34], 58, [34,<<"transfer_central">>,34], 44, [34,"doc_count",34], 58,"39441",44, [34,"doc_del_count",34], 58,"0",44, [34,"...

Send a "304 Not Modified" for images stored in the datastore

I store user-uploaded images in the Google App Engine datastore as db.Blob, as proposed in the docs. I then serve those images on /images/<id>.jpg. The server always sends a 200 OK response, which means that the browser has to download the same image multiple time (== slower) and that the server has to send the same image multiple times...

HTTP Handlers in Win2008/IIS7

We are migrating our web sites from Win2003/IIS6 to Win2008/IIS7. Our .NET code is in a WAP form with compiled binaries. I do dev work on a Win7/IIS7 box so had to learn early how to set up HTTP Handlers in this newer environment. What I have that has worked fine on my box is: <system.webServer> <handlers> <remo...

change the "save image as..." name of images produced by an http handler in .net

I have a series of images stored in a MySQL database that I am displaying with a .NET Http handler (showImage.ashx). If the user right clicks on an image and selects "save image as...", the image name always defaults to 'showImage.jpg'. I have potential image names saved in the database, is there any way to control the default save nam...