473,659 Members | 2,662 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

httpHandler for asp

I am looking to write an httpHandler to process incoming asp requests. I
need to process the asp script with the asp.dll and then format the response
(I need to rewrite url and image paths based on the current virtual
directory). Is this possible? Any suggestions would be appreciated.

thanks
Nov 19 '05 #1
2 1497
Hi Phil,

Not with classic ASP. You can do this with ASP.NET.

For classic ASP you'd have to use an ISAPI filter to do this most likely.

Maybe there's a way you can do what you need from within the ASP code and
some client side scripting?
Hard to tell by the limited description you give here...
+++ Rick ---
"Phil" <Ph**@discussio ns.microsoft.co m> wrote in message
news:7F******** *************** ***********@mic rosoft.com...
I am looking to write an httpHandler to process incoming asp requests. I
need to process the asp script with the asp.dll and then format the response (I need to rewrite url and image paths based on the current virtual
directory). Is this possible? Any suggestions would be appreciated.

thanks

Nov 19 '05 #2
I figured that it would not work... The basic idea behind what I am trying
to do is the following: Staging and production web servers have separate web
sites for each web application, however, development is a little different.
Each developer has a web site on development and uses a separate virtual
directory for each web application. The problem that I need to resolve
occurs when their is a image or link whose path is pointing to the root of
the application. This works fine on staging and production, but on
development it points to the root web site instead of the virtual directory.
As a result the image and link url's are incorrect. I do not want to have to
go through and change the code so what I want to do is reformat the response.
I currently do it using the MSXML object, but it is a little slow because it
is making two requests to every page. Maybe javascript onload is the answer?
Do you have any ideas? Thanks again for your response.

"Rick Strahl [MVP]" wrote:
Hi Phil,

Not with classic ASP. You can do this with ASP.NET.

For classic ASP you'd have to use an ISAPI filter to do this most likely.

Maybe there's a way you can do what you need from within the ASP code and
some client side scripting?
Hard to tell by the limited description you give here...
+++ Rick ---
"Phil" <Ph**@discussio ns.microsoft.co m> wrote in message
news:7F******** *************** ***********@mic rosoft.com...
I am looking to write an httpHandler to process incoming asp requests. I
need to process the asp script with the asp.dll and then format the

response
(I need to rewrite url and image paths based on the current virtual
directory). Is this possible? Any suggestions would be appreciated.

thanks


Nov 19 '05 #3

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

Similar topics

2
2120
by: Hanse Davion | last post by:
Can anyone provide some insight on what this problem could be? I have searched the web, read forums, and all the installation documentation for the dotnetnuke feeware portal from asp.net. I am very confident that all the security settings have been configured correctly. My setup is a Windows XP 5.1, MSDE SP3, and VS2003. ----------------------------- Server Error in '/DotNetNuke' Application....
3
7957
by: Jed | last post by:
I have written an HttpHandler which I invoke through an ashx page. The HttpHandler does various things to process the request, then it is supposed to redirect to a confirmation page. Everything up to the redirect works fine, but I can't get the redirect to work. If I do a ... context.Response.Write("Hello World"); .... the HttpHandler works great and the browser loads the text fine, but if I change it to ...
4
5034
by: Jeremy Lew | last post by:
When my HttpHandler is processing a request when installed on a particular 2003 Server machine, the Context.Session object is null. Any idea why this might be? My handler implements IRequiresSessionState and works normally on other machines. Thanks, Jeremy
3
1776
by: Ralf Müller | last post by:
hi all! in my custom HttpHandler HttpContext.Current.Session is not set - why? greetings, ralf
9
3308
by: Jared Tullis | last post by:
We have an .NET 1.1 application running on 4 2K3 load balanced servers (using WLBS). IIS has the .NET aspnet_isapi.dll mapped as a wildcard application map. The web.config points *.html to a HttpHandler of our design. This setup serves over a million page views daily with almost no hassle whatsoever. We have brought a few affiliates onto our system who have URLs still floating in Google, Y! and other search engines from before they...
7
2911
by: Adam | last post by:
Im trying to add an httphandler for all *.sgf file extensions. I have developed the handler, 1. installed it into the gac 2. added it to the machine.config: <httpHandlers> <add verb="*" path="*.sgf" type="CustomExtensionHandler, Extenders.CustomExtensionHandler, Version=1.0.0.0, Culture=neutral, PublicKeyToken=d831d925597c1031" validate="True"/> </httpHandlers>
8
3889
by: bryan | last post by:
I've got a custom HttpHandler to process all requests for a given extension. It gets invoked OK, but if I try to do a Server.Transfer I get an HttpException. A Response.Redirect works, but I really need to avoid the extra round-trip to the client. I've tried Passing the page name, the full URL, and the instance of the handler class to the Transfer method, but everything gets me the same error 500. Any help would be appreciated.
5
1597
by: the4man | last post by:
Hi all! I have an app that show images that are stored in SQL Server. To show the images on screen, until now (with the "old" ASP), I use the following code: <img src="showimage.asp?id=20" /> And in "showimage.asp" (more or less, I write from memory)
5
4311
by: zlf | last post by:
Hello, I try to use a custom HttpHandler to add something to session, then display the original page. public void ProcessRequest(HttpContext context) { context.Session = "test"; } But, a empty page is rendered with this HttpHandler, should I add some
5
7300
by: Author | last post by:
I followed the example at http://support.microsoft.com/kb/308001/EN-US/ and created my own HttpHandler. Here is the code: using System.Web; namespace MyNameSpace { public class SyncHttpHandler: IHttpHandler
0
8427
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
8850
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8746
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
8523
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,...
0
8626
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7355
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6178
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
4334
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2749
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.