The only problem is that if there are any files on the website which start with the text "english" then the rule would apply to that filename. I have an image called english-rose.jpg which would not display when this rule was in place. As soon as I removed the rule it was fine.
So what I want is to change the rule so it only matches on /english and no other variation.
Microsoft IIS Web ServerRegular Expressions
Last Comment
NerdsOfTech
8/22/2022 - Mon
Dan McFadden
Try this:
<rule name="Rewrite english to /index.asp"> <match url="english/" /> <action type="Rewrite" url="index.asp" /> </rule>
Thanks Dan. While this has solved the issue of the image now being recognised, the problem I have now is that the URL only works with the forward slash in front like so: www.mywebsite.com/english/
Open in new window
Dan