Search code examples
asp.netweb-configumbraco7

looking for a way to redirect everything under a path in web.config


I'm looking for a way to redirect user when they want to access for example www.domainname.com/products/car/volvo/car1 to www.domainname.com/products/ i'm using umbraco to build the site


Solution

  • Rather than handling such requests from the application's web.config, you could have the web server (IIS) redirect the requests. Please refer below link on how you may do so.

    https://www.iis.net/configreference/system.webserver/httpredirect?showTreeNavigation=true