I have some javascript that is in my application that keeps deleting a cookie that I am setting elsewhere in my application. I do NOT want to delete the said cookie, called 'UserRegion'. Here is the javascript:
function removeCookies(){
Runtime Error in QADS, check if document exists
if (document.orderdetail){
if(document.orderdetail.closer.value == 0)
{
expires = new Date
expires.setMonth(expires.getMonth() - 1)
if (document.cookie != ""){
thisCookie = document.cookie.split("; ")
for (x=0; x < thisCookie.length; x++){
document.cookie = thisCookie[x].split("=")[0] + "=;expires=" + expires.toGMTString()
}
}
}
}
}
How do I add code to this so that it overlooks the cookie named, 'UserRegion', and does not delete it or basically change it to expire.
THANKS!!!!!!
function removeCookies(){
Runtime Error in QADS, check if document exists
if (document.orderdetail){
if(document.orderdetail.closer.value == 0)
{
expires = new Date
expires.setMonth(expires.getMonth() - 1)
if (document.cookie != ""){
thisCookie = document.cookie.split("; ")
for (x=0; x < thisCookie.length; x++){
document.cookie = thisCookie[x].split("=")[0] + "=;expires=" + expires.toGMTString()
}
}
}
}
}
How do I add code to this so that it overlooks the cookie named, 'UserRegion', and does not delete it or basically change it to expire.
THANKS!!!!!!