// parse location.hostname into parts so we can get some info about the host request url
var hostparts = null;
var host_subdomain = null;
var host_domain = null;
var host_suffix = null;

hostparts = location.hostname.split('.');

if (hostparts[0] == "planwithvoyant" || hostparts[0] == "voyantplanner") {
    // no subdomain, assume url is domain.[com|co.uk]
    host_domain = hostparts[0];
    host_subdomain = "www";
} else {
    // we assume format of url is subdomain.domain.[com|co.uk]
    //  we assume no . it subdoman
    host_subdomain = hostparts[0];
    host_domain = hostparts[1];
}

if (location.hostname.indexOf('co.uk') != -1) {
    host_suffix = ".co.uk";
} else {
    host_suffix = ".com";
}

