var expire = new Date(); expire.setTime(new Date().getTime() + 1000 * 60 * 60 * 24 * 365); document.cookie = "cookiename=data;expires=" + expire.toGMTString() + ";path=/;domain=www.newcastle.nsw.gov.au"; 