Language/Javascript
location.href 시 referrer가 남지 않는 문제 해결
미니옵빠
2011. 7. 11. 15:22
function navigateWithReferrer(url) {
var linkObj = document.createElement("a");
if (typeof(linkObj.click) == "undefined" || typeof(linkObj.click) == "function") {
window.location.href = url; // Not IE
} else {
linkObj.href = url;
document.body.appendChild(linkObj);
linkObj.click(); // Only IE
}
}
var linkObj = document.createElement("a");
if (typeof(linkObj.click) == "undefined" || typeof(linkObj.click) == "function") {
window.location.href = url; // Not IE
} else {
linkObj.href = url;
document.body.appendChild(linkObj);
linkObj.click(); // Only IE
}
}
솔직히 다른 브라우져 다 테스트는 못해봤음 -_-;