[英]asp-classic Not working Request.ServerVariables(“HTTP_REFERER”) in Internet Explorer
我正在使用Internet Explorer在使用javascript代碼window.open的地方運行一些代碼。 這是下面的示例代碼。 這寫在頁面r_test1.asp中
<script type="javascript">
window.open('r_test2.asp');
</script>
打開一個命名為r_test2.asp的窗口,我正在嘗試獲取引薦來源。 頁面r_test2的代碼是
response.Write(request.ServerVariables("HTTP_REFERER"))
問題是我在mozilla或chrome中獲得了引薦來源網址,但在Internet Explorer中卻無法獲得引薦來源,我在那里急需它
當您使用window.open事件時,Internet Explorer確實不會傳遞引用。
以前在StackOverflow上已發布了一種不錯的替代解決方案(以模仿單擊超鏈接的方式,以便IE確實設置了引薦來源):
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.