Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Simone Chiaretta 130 posts 516 karma points c-trib
    Dec 08, 2016 @ 09:12
    Simone Chiaretta
    0

    Performing 301 redirects

    Hi, the site I'm setting up has 2 domains: www.example.com and example.com.

    To retain the canonical Url I'd like to have all requests to www.example.com to be 301 redirected to example.com.

    Normally I'd just write a IIS rewrite URL rule, but with umbraco I've seen there is already a rewrite module inside, called UrlRewriting.Net.

    Also, since 7.5 there is already a 301 redirect solution that checks for moves and creates rules automatically.

    So, I've 2 questions:

    1. Is there way to add new rules to the the 301 tracking table so that the module does it's job for me?
    2. If no, is it better to use UrlRewriting.Net or using the IIS rewrite module?

    Thx

    Simone

  • Damiaan 438 posts 1290 karma points MVP 3x c-trib
    Dec 08, 2016 @ 10:51
    Damiaan
    100

    The answer is simple:

    1. No, you should not add something yourself. It is build to catch renames of nodes. Because it's only a fallback before a 404 would happen, it's pretty slow too.
    2. IIS rewrite module all the way, UrlRewriting.net will be removed in v8.

    Also, look at the documentation for url tracking

    Kind regards

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies