Copied to clipboard

Flag this post as spam?

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

  • Jaffar Shehab 3 posts 73 karma points
    Mar 27, 2018 @ 07:57
    Jaffar Shehab

    How to add DomainRoute


    I would like to display my customer name in the domain like


    I have tried to add DomainRoute such as the pure MVC but it is not working in umbraco

    /****For Pure MVC***/
    routes.Add("DomainRoute", new DomainRoute( 
        "{storeName}",     // Domain with parameters 
        "{controller}/{action}/{id}",    // URL with parameters 
        new { language = "en", controller = "Home", action = "Index", id = "" }  // Parameter defaults 

    How to add the {storeName} parameter to the domain as a prefix?

    Site setup: - One Umbraco websites - Each store is a database record; not a single website

  • John Churchley 272 posts 1254 karma points c-trib
    Mar 27, 2018 @ 08:18
    John Churchley

    Make sure you binding are set correctly in IIS. Then right click the homenode and under Culture & Hostnames add the subdomain for the corresponding site.

  • Jaffar Shehab 3 posts 73 karma points
    Mar 27, 2018 @ 08:53
    Jaffar Shehab

    Thank you very much John for the quick answer.

    but this will not work for my case, the storeName is a dynamic parameter taken form database that contains an increasing number of stores records.

Please Sign in or register to post replies

Write your reply to: