Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 26542

Remotely rewrite gives 404

$
0
0

Hello,

I'm using IIS 7.5 and URL Rewrite 2.0 and a simple rewrite rule works locally but not remotely.

<rule name="RewriteUserFriendlyURL1" stopProcessing="true"><match url="^test$" /><conditions><add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /><add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /></conditions><action type="Rewrite" url="test.php" /></rule>

I was reading this tutorial http://www.iis.net/learn/extensions/url-rewrite-module/user-friendly-url-rule-template and just created a rule like:

www.domain.com/test
should be rewritten to
www.domain.com/test.php

And it works when I request www.domain.com/test locally: test.php is shown.
But when requesting remotely from my browser at home, I get a 404.0 (I enabled detailed errors for that moment):

Module    IIS Web Core
Notification    MapRequestHandler
Handler    StaticFile
Error Code    0x80070002
Requested URL    http://www.domain.com:80/test/
Physical Path    C:\inetpub\www\domain\test\
Logon Method    Anonymous
Logon User    Anonymous

So it seems the rewrite rule has no effect when the request comes from "outside". Why is that?

Thanks!


Viewing all articles
Browse latest Browse all 26542

Trending Articles