Copied to clipboard

Flag this post as spam?

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


  • Sherry Ann Hernandez 320 posts 344 karma points
    Oct 31, 2011 @ 10:15
    Sherry Ann Hernandez
    0

    redirecting a hostname to a specific page

    Hi,

    I have two hostname in one umbraco installation and the other hostname directs to a specific page. How can I redirect http://www.site.com to http://www.site.com/page1.aspx and http://www.site/com/ar to http://www.site.com/ar/page1.aspx

    Any ideas?

     

  • Jacob Jensen 40 posts 60 karma points
    Oct 31, 2011 @ 10:24
    Jacob Jensen
    0

    in urlrewriting.config:

    <add name="Site1"
                  virtualUrl="^~/"
                  rewriteUrlParameter="ExcludeFromClientQueryString"
                  destinationUrl="~/page1.aspx"
                  ignoreCase="true" />

            <add name="Site2"
                  virtualUrl="^~/com/ar"
                  rewriteUrlParameter="ExcludeFromClientQueryString"
                  destinationUrl="~/ar/page1.aspx"
                  ignoreCase="true" />

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 31, 2011 @ 10:26
    Fuji Kusaka
    0

    You could add a Property in your Document Type with alias "umbracoRedirect", Type Content Picker. 

    Then under your Content Section choose the page under which you want the page to be redirected to.

     

  • Sherry Ann Hernandez 320 posts 344 karma points
    Oct 31, 2011 @ 12:36
    Sherry Ann Hernandez
    0

    Hi Jacob,

    The virtual url ~/ will redirect the main hostname right? But in my umbraco installation I setup two hostname. the ~/ pertains to the first hostname and the 2nd hostname is www.site2.com

    Hi Fuji,

    The umbraco redirect doesn't recognize the querystring that I have. That's why I didn't use it.

  • Fuji Kusaka 2203 posts 4220 karma points
    Oct 31, 2011 @ 13:24
    Fuji Kusaka
    0

    When you go you under your Content Section and choose the document Type cant you pick up a node?

  • 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