[Mono-aspnet-list] HttpContext.RewritePath is not working

vtortola vtortola at gmail.com
Tue Apr 6 16:14:23 EDT 2010


Hi,

I've written a handler for the extension ".myext" and it's working fine in
Windows with .NET and IIS, and in Linux with Mono and Apache. The handler
returns an XML whatever be the url. In both machines I can do:

http://localhost/mytestapp/go.myext/
http://localhost/mytestapp/go.myext/lalala
http://localhost/mytestapp/go.myext/lalala/lelele

And I'll always get the XML.

Now I've written a module that rewrites the path in this way in the
BeginRequest event:

context.RewritePath(context.Request.AppRelativeCurrentExecutionFilePath.Replace("~/",
"~/go.myext/"));

Then in the Windows/.NET/IIS machine i can obtain the XML doing:

http://localhost/mytestapp/
http://localhost/mytestapp/lalala
http://localhost/mytestapp/lalala/lelele

But not in the Linux/Mono/Apache machine. So I guess that RewritePath is not
working in Mono or I need to do something in the configuration to enable
this behavior.

What is the problem?

Kind regards.
-- 
View this message in context: http://n4.nabble.com/HttpContext-RewritePath-is-not-working-tp1753422p1753422.html
Sent from the Mono - ASP.NET mailing list archive at Nabble.com.


More information about the Mono-aspnet-list mailing list