Copied to clipboard

Flag this post as spam?

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


  • Roger 195 posts 474 karma points
    May 20, 2014 @ 14:40
    Roger
    0

    URL Redirecting issue

    Hi guys, im having a URL redirect issue if anyone can help me please?

    I have a multilingual website with 2 cultures: /en (english) and /cy (welsh)

    The main URL for the english version is lovefostering.co.uk and for the welsh version its carumaethu.co.uk

    The client wants carumaethu.co.uk to hit the /cy to present the user with the correct language from the correct URL.

    I have set up all the bindings in IIS with both domains and if I type in carumaethu.co.uk/cy it all works fine.

    My issue is:

    How do I send requests from carumaethu.co.uk and www.carumaethu.co.uk to carumaethu.co.uk/cy

    Either in IIS or using Umbraco itself.

    Many thanks in advance!

  • Amir Khan 1289 posts 2746 karma points
    May 20, 2014 @ 15:51
    Amir Khan
    0

    Hi Roger! If I'm understanding you correctly, you should be able to right-click on the cy and en nodes and select "Culture and Hostnames" and enter your FQDN in there. Umbraco should take care of the rest!

    -Amir

  • Roger 195 posts 474 karma points
    May 20, 2014 @ 16:21
    Roger
    0

    Thanks Amir, That almost works. hostnames don't seem to support www. and non www.

    I have set carumaethu.co.uk in the culture and hostnames. This works great but if you type in www.carumaethu.co.uk It defaults to the english version.

    Roger

  • Amir Khan 1289 posts 2746 karma points
    May 20, 2014 @ 16:25
    Amir Khan
    0

    Ah, you can add both the www and non-www versions to the culture and hostnames settings, or use the following redirect in your urlrewriting.config. I tend to prefer the redirect method to canonicalize the urls.

    -Amir

    <add name="domainRewrite"
    virtualUrl="http://yourdomain.com/(.*)"
    rewriteUrlParameter="ExcludeFromClientQueryString"
    destinationUrl="http://www.yourdomain.com/$1"
    redirect="Domain"
    redirectMode="Permanent"
    ignoreCase="true" />
  • 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