Copied to clipboard

Flag this post as spam?

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


  • Marco 6 posts 26 karma points
    Sep 02, 2009 @ 12:08
    Marco
    0

    get the hostname language settings

    Hi to all, I'm developing a new web site with umbraco v.4 The site have 2 language and i have created 2 root nodes with 2 hostnames, one is www.mysite.com with language italian and the other is en.mysite.com with language english. If i have a macro (who use an usercontrol) inserted in a page under one of the 2 root nodes is possible to get the language of the parent node? I'm using .net in version 2.0 Thank's 4 the help! Marco

     

  • Richard Soeteman 3875 posts 12037 karma points MVP
    Sep 02, 2009 @ 13:01
    Richard Soeteman
    0

    Hi Marco,

    You could try umbraco.library.GetCurrentDomains(nodeId)[0].Language This returns the first assigned language

    Cheers,

    Richard

  • Marco 6 posts 26 karma points
    Sep 02, 2009 @ 15:18
    Marco
    0

    Hi Richard, thank you for the reply, 

    i think you are right, but now i have an other problem.

    In VS 2008 i have the umbraco solution where i'm working, with the reteference at all the umbraco' s dll, but when i try to use umbraco.library doesn't work, visual studio doesn't know what is... :(

    Any ideas?

     

    Thank for your help..

     

    Marco

  • Marco 6 posts 26 karma points
    Sep 02, 2009 @ 16:09
    Marco
    0

    ok i have found the problem, the namespace of the user control was incorrect, i have put my usercontrol into umbraco namespace and all work fine.

    Marco

  • 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