<div class="post-text" itemprop="text">
How can I do a 301 redirect with this pattern: /([^/]+)(?=/[^/]+/?$) in my .NET solution to redirect /en/solutions/exemple to /en/exemple in my web.config file
PS:I am new to .NET and IIS that's why I am asking
<system.webServer><rewrite><rules><rule name="regex redirect" stopProcessing="true"><match url=".*" /><conditions><add input="{HTTP_HOST}" pattern="\/([^\/]+)(?=\/[^\/]+\/?$)" /></conditions><action type="Redirect" url="/en/solutions/exemple" redirectType="Permanent" /></rule></rules></rewrite>
Thanks
</div>