Good morning
I've been tasked with setting some redirections but I can't get subdirectories to work.
I've already redirected domain with code. This part works fine
<rule name="Redirects domain1.co.uk to domain2.co.uk" patternSyntax="ECMAScript" stopProcessing="true"><match url=".*" /><conditions logicalGrouping="MatchAny"><add input="{HTTP_HOST}" pattern="^(www.)?domain1.(com|co.uk)$" /></conditions><action type="Redirect" url="https://www.domain2.co.uk/{R:0}" /></rule>
Now I am trying to redirect some highly ranked subs but I am not getting any luck with below code. Any help would be appreciated.
<rule name="Subdirectory 1" patternSyntax="ECMAScript" stopProcessing="true"><match url=".*" /><conditions logicalGrouping="MatchAny"><add input="{HTTP_HOST}" pattern="^(www.)?domain1.(com|co.uk)$" /><add input="{PATH_INFO}" pattern="subdirecotory-A$" /></conditions><action type="Redirect" url="https://www.domain2/subdirectory-B/{R:0}" /></rule>
Lukasz