Copied to clipboard

Flag this post as spam?

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


  • vijay 129 posts 152 karma points
    Dec 22, 2009 @ 13:51
    vijay
    0

    How to assign domain to a node programatically?

    Can any one tell me How to assign domain to a node programatically?

    Thanks in advance

    vijay.

  • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
    Dec 22, 2009 @ 14:00
    Dirk De Grave
    0

    vijay,

    Here's a link to the api docs to assign domains programmatically

     

    Cheers,

    /Dirk

  • El Cid 8 posts 28 karma points
    Jun 23, 2014 @ 09:47
    El Cid
    0

    Hello Dirk, The link you mention is dead now.

    Could point me in a direction, or is it a new way to do this. I have to set-up a lot of websites(domaians) (60+) and I would like not do it manually.

    Thanks.

  • Joachim Andersen 38 posts 198 karma points
    Jun 25, 2014 @ 22:58
    Joachim Andersen
    0

    Hi

    You can add a domain to a node using the following code:

    umbraco.cms.businesslogic.web.Domain.MakeNew("http://domain.com", nodeId, languageId);

    Cheers, Joachim

  • 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