How to handle Clean URIs in Classic ASP using PATH_INFO?

Posted by Mario on Stack Overflow See other posts from Stack Overflow or by Mario
Published on 2010-06-08T20:09:42Z Indexed on 2010/06/08 20:12 UTC
Read the original article Hit count: 255

Filed under:

I'm trying to handle Clean URIs in a Classic ASP application.

In PHP, I was able to use URIs like http://example.com/index.php/foo/bar/baz and have /foo/bar/baz available in the PATH_INFO environment variable. (I usually add a rewrite rule so I do not need the index.php segment)

However, I don't seem to be able to mimic this in Classic ASP. If I try http://example.com/index.asp/foo/bar/baz, I get a 404 error.

Is there a way to add a path after the index.asp segment and get the PHP like behaviour in ASP?

Note:

I'm currently using the workaround of rewriting URLs of the form: http://example.com/foo/bar/baz/ to index.asp?path=/foo/bar/baz since I can't seem to get index.asp/foo/bar/baz to work.

© Stack Overflow or respective owner

Related posts about asp