Copied to clipboard

Flag this post as spam?

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


  • Thomas Dolberg 74 posts 95 karma points
    Aug 15, 2011 @ 22:56
    Thomas Dolberg
    0

    redirecting a node to a single url

    Hi

     

    right now I can access a node with the following URLs (at least):

    - nodeName.aspx

    - nodeName

    - nodeName/

     

    how do I setup urlrewriting so all other requests for the node will permanently redirect to "nodeName/" ? I want to do it, because Google will see the above three URLs as three different pages and think it is duplicate content.

     

    thanks

    Thomas

  • Stefan Kip 1614 posts 4131 karma points c-trib
    Aug 15, 2011 @ 23:40
    Stefan Kip
    0

    Hi Thomas,

    I've put together a regex for you to do this:

    ^([^/]+?)(?:\.aspx)?$

    This will match string like 'nodename.aspx' and 'nodename' (without an ending slash). They both capture 'nodename', so you'll have to redirect to '{R:1}/' which means '<group1>/'.

    Greets.

  • Thomas Dolberg 74 posts 95 karma points
    Aug 20, 2011 @ 20:22
    Thomas Dolberg
    0

    Hi kipusoep

     

    thanks for the regex.

     

    I ended up using the rewrite URLs at http://umbraco.miketaylor.eu/2010/11/03/url-rewriting-and-seo/ since they cover all the things I need.

     

    best regards

    Thomas

  • 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