Copied to clipboard

Flag this post as spam?

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


  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Apr 04, 2017 @ 17:48
    Lee Kelleher
    0

    SiteDomainHelper - explicitly add domain protocol?

    I'm using the SiteDomainHelper API on my multi-domain'd project. So far I've been adding the domain values like so...

    SiteDomainHelper.AddSite("live", "domain1.com", "domain2.com");
    

    Recently some of my domains have become HTTPS, and I've had to specify the hostname in the CMS as "https://domain1.com".

    Does anyone know if I need to be explict with the SiteDomainHelper API? Does the value need to be "domain1.com" or "https://domain1.com"?

    This is probably a question more for Stephan than anyone else, but please do feel free to chip in :-)

    Thanks,
    - Lee

  • Stephen 767 posts 2273 karma points c-trib
    Apr 05, 2017 @ 09:33
    Stephen
    1

    (checking)

  • Stephen 767 posts 2273 karma points c-trib
    Apr 05, 2017 @ 10:44
    Stephen
    100

    With...

    SiteDomainHelper.AddSite("live", "domain1.com", "domain2.com");
    

    It will work for http and https, ie if current request is http, it will map to http, and if current request is https, it will map to https. So even though you specify your domains with "https://domain.com" you can leave the SiteDomainHelper as-is.

  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Apr 05, 2017 @ 10:57
    Lee Kelleher
    0

    Cool, thanks Stephan!

Please Sign in or register to post replies

Write your reply to:

Draft