简体   繁体   中英

IIRF url rewriting with IIS 6

I want to rewrite this url:

"www.mydomain.com/myproject/index.php?function=demo"

to

'www.mydomain.com/myproject/home/demo'

and I have this code in my iirf.ini file:

RewriteEngine on
StatusInquiry On  /iirfSatus
RewriteLog c:\Inetpub\
RewriteLogLevel 3
RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^/myproject/home/(.*)$ /myproject/index.php?function=$1 [L]

I still get a 404 error when I surf to the second link, and I don't know why. Any help would be appreciated!

I found the problem myself after another hour of searching the web: The problem was that my Iirf.ini file was in the wrong folder. It was in the wwwroot instead of my project folder. It works fine now

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