开发者

url referrer problem in gmail

开发者 https://www.devze.com 2023-01-15 12:15 出处:网络
I am getting Url referer in global asax file. try { if (Session[\"url\"] == null && !Request.UrlReferrer.ToString().StartsWith(\"http://www.myd开发者_StackOverflowomain\") && !Reques

I am getting Url referer in global asax file.

 try
    {
        if (Session["url"] == null && !Request.UrlReferrer.ToString().StartsWith("http://www.myd开发者_StackOverflowomain") && !Request.UrlReferrer.ToString().StartsWith("http://mydomain"))
            Session["Url"] = Request.UrlReferrer;
    }
    catch { }

Its working, but if the url in gmail dosent work. How canI get Url Referrer from gmail? Thanks


If by "doesn't work" you mean that you are getting a null value then that is because URLReferrer header is not sent for SSL requests and Gmail uses SSL. This is intended - http://www.w3.org/Protocols/rfc2616/rfc2616-sec15.html#sec15.1.3

0

精彩评论

暂无评论...
验证码 换一张
取 消