简体   繁体   中英

IIS 7.5 Custom Errors and URL Rewrite

I was looking at both of these options in IIS to try and accomplish the compounding of querystrings to appear like file directories.. like this:

/search/

/search/janice

/search/janice/cooper

Whereas the original URL is something like /search?fname=janice&lname=cooper

I tried the URL Rewrite method, but it doesn't allow optional fields (for querystrings)

I tried custom 404 error, and it gets the REFERER of the original script, but the script itself cannot accessed by URL, only be referral, so this won't work either..

Does anyone have any suggestions on how to accomplish something like this?

Here is one method to achieve it: URL Rewriting in classic ASP

The best way to achieve the concatenating of query strings to end up as URL routing is to upgrae the project to be ASP.Net and use ASP.NET Routing .

If you are in the middle of upgrading and wish to be able to switch over easily without broken links and losing google ranking when links change is to use Helicon ISAPI Rewrite

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM