FAQ: Why don't you automatically rewrite URLs in outgoing pages?
The question pertains to the following scenario - you have Web pages, and those sport
several links like this in the HTML code:
<a href="http://www.mywebstore.com/product.asp?pid=20001">Some link</a>
What you have to do with PortalPageFilter is rewrite these URLs using our rewriting
functionality, which is implemented in ASP. There is no functionality in PortalPageFilter
that automatically scans outgoing pages for links and fixes them - why? (would
be convenient, wouldn't it?)
The reason is rooted in the way this must be implemented.
The only way to implement this would be to add the filter event SF_NOTIFY_SEND_RAW_DATA.
However, the article
Developer Notes for ISAPI Filters
strongly advises not to do that:
"Some filter notifications are very expensive in terms of CPU resources and I/O
throughput (most notably SEND_RAW_DATA), and can have a significant effect on the speed
and scalability of IIS."
If we had implemented this, your server would take an enormous performance hit, because
every outgoing page must be scanned character-by-character. Instead of slowing down
each and every page request, we decided to let you choose when to use PortalPageFilter's
URL rewriting, and retain scalability on your Web server.