Running classic ASP under .NET

  • Thread starter Thread starter David
  • Start date Start date
D

David

Hi,

I am attempting to do URL ReWriting with .NET to my classic ASP app. (Too
big to upgrade to .NET at the moment). However, those who have tried will
know that classic asp when rewritten doesn't work.

Speaking to a friend of mine, he says (and I am sure I have seen it before
as well) that I can run the classic ASP under the aspnet isapi. However, I
can't find how to do that.

Any ideas?

For the re-writing, I am using .NET 1.1 (as I already have other things on
the site using 1.1)
--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
 
This gives an overhead view or URL rewriting and how to replace the http
"filters" in .NET.

http://msdn.microsoft.com/en-us/library/ms972974.aspx

The replacement of the "filters" is shown near the top. I would read
further, as understanding what is going on behind the scenes may make
something click.

In URL rewriting, you are merely taking a request, say
http://www.mysite.com/calendar/10/8/2008/ and turning it into something like
http://www.mysite.com/calendar.asp?date=10/8/2008. As long as you have the
correct handling of the request, you should be able to redirect to any type
of page you desire. In theory, it should not matter what page you are
redirecting the user to. In practice, this may not be the case. I have never
rerouted to a classic ASP page. But, once again, understanding what is going
on behind the scenes can often lead to an AHA moment.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
 
Hi,

I know how url-rewriting works, having implemented it on many .net sites.

I cannot see how to apply it to work with classic asp. That doc doesn't
really go into it.

I have tried changing the isapi filter from asp.dll to aspnet_isapi.dll but
that just gives me an error for ALL my asp pages before I have even
rewritten the url (it happens to be the same error, something to the effect
of "This page cannot be served."

Looks like it isn't going to be that easy, unless I use a 3rd party isapi.
--
Best regards,
Dave Colliver.
http://www.AshfieldFOCUS.com
~~
http://www.FOCUSPortals.com - Local franchises available
 
unless you are using iis 7.0, which can be configured to support .net
pipelines, a url rewriter for asp (or any non asp.net request) must be
written as an isapi filter, which must be coded in c/c++

-- bruce (sqlwork.com)
 
It looks like Bruce found the answer, although you do have some choices
other than C++ or C (any language you can write a native DLL in will work,
C++ and C are the norm and the only ones I know of that will work with
Visual Studio):

Look here for ISAPI filter examples:
http://www.genusa.com/isapi/isapisrc.html

There is a filter already written for changing URLs, written in Delphi:
http://www.genusa.com/isapi/chgurl.zip

There is also this one, although it will require some tweaking to do what
you desire:
http://www.genusa.com/isapi/iisipmap.zip

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
 
Back
Top