How can I get the domain name with jquery ??
//If url is something.domain.com this returns -> domain.com function getDomain() { return window.location.hostname.replace(/([a-zA-Z0-9]+.)/,""); }