http-referer

Specifying HTTP referer in embedded UIWebView

馋奶兔 提交于 2019-11-27 04:16:30
In my app, I allow the user to open up an external page in an embedded UIWebView. Is it possible for me to set the referer header that's sent with that request? I'd like for my app to get the 'cred' when the user opens up these external pages. Set the referer using - setValue:forHTTPHeaderField: NSMutableURLRequest* request = ...; [request setValue:@"https://myapp.com" forHTTPHeaderField: @"Referer"]; But note that according to the HTTP RFC you shouldn't, because your app is not addressable using a URI: The Referer field MUST NOT be sent if the Request-URI was obtained from a source that does

Alternative for $_SERVER['HTTP_REFERER'] PHP variable in MSIE

放肆的年华 提交于 2019-11-26 20:56:31
问题 I have used $_SERVER['HTTP_REFERER'] variable in my application (used PHP). On Firefox above variables is wokring. But i observed that $_SERVER['HTTP_REFERER'] is not working on Microsoft Internet Explorer 8. I also got to know that HTTP_REFERER variable doesnt work on MSIE8 and MSIE7. Please give me your suggestions, how to use $_SERVER['HTTP_REFERER'] variable to get rid on MSIE7/8 or is there any other alternative for $_SERVER['HTTP_REFERER'] variable Thanks for your suggestion. -Pravin.

Is it possible to capture search term from Google search?

霸气de小男生 提交于 2019-11-26 15:55:32
问题 This may be a stupid question, but is it possible to capture what a user typed into a Google search box, so that this can then be used to generate a dynamic page on the landing page on my Web site? For example, let's say someone searches Google for "hot dog", and my site comes up as one of the search result links. If the user clicks the link that directs them to my Web site, is it possible for me to somehow know or capture the "hot dog" text from the Google search box, so that I can call a

Get original URL referer with PHP?

这一生的挚爱 提交于 2019-11-26 15:47:39
I am using $_SERVER['HTTP_REFERER']; to get the referer Url. It works as expected until the user clicks another page and the referer changes to the last page. How do I store the original referring Url? Store it either in a cookie (if it's acceptable for your situation), or in a session variable. session_start(); if ( !isset( $_SESSION["origURL"] ) ) $_SESSION["origURL"] = $_SERVER["HTTP_REFERER"]; As Johnathan Suggested, you would either want to save it in a cookie or a session. The easier way would be to use a Session variable. session_start(); if(!isset($_SESSION['org_referer'])) { $_SESSION

Will a 302 redirect maintain the referer string?

扶醉桌前 提交于 2019-11-26 15:12:23
I need to redirect the user from one page to another, but I need to maintain the original referer string. So, for example, if they start out on http://www.othersite.com/pageA.jsp , click a link that takes them to http://www.mysite.com/pageB.jsp , which then executes a 302 redirect to http://www.mysite.com/pageC.jsp , I need the referer string to contain " http://www.othersite.com/pageA.jsp " Is this the normal behavior for a 302 redirect? Or would my original referer get dropped, in favor of " http://www.mysite.com/pageB.jsp " ? That would not be desirable. I don't know if it makes any

PHP - Referer redirect script

笑着哭i 提交于 2019-11-26 14:29:50
问题 Often, when searching for answers, I have found that certain websites will allow you to read the information they offer if the referer is, for example, google.com. Yet, if you link directly to the information, it will be unavailable. What I am looking for is the smallest PHP script that will set a referer of my choice, and a destination, like so: http://example.com/ref_red.php?referer=http://google.com/&end=http://example.net/ Notes: ref_red.php is the name of the script on my example.

Specifying HTTP referer in embedded UIWebView

≯℡__Kan透↙ 提交于 2019-11-26 11:07:24
问题 In my app, I allow the user to open up an external page in an embedded UIWebView. Is it possible for me to set the referer header that\'s sent with that request? I\'d like for my app to get the \'cred\' when the user opens up these external pages. 回答1: Set the referer using - setValue:forHTTPHeaderField: NSMutableURLRequest* request = ...; [request setValue:@"https://myapp.com" forHTTPHeaderField: @"Referer"]; But note that according to the HTTP RFC you shouldn't, because your app is not

Get original URL referer with PHP?

丶灬走出姿态 提交于 2019-11-26 05:59:55
问题 I am using $_SERVER[\'HTTP_REFERER\']; to get the referer Url. It works as expected until the user clicks another page and the referer changes to the last page. How do I store the original referring Url? 回答1: Store it either in a cookie (if it's acceptable for your situation), or in a session variable. session_start(); if ( !isset( $_SESSION["origURL"] ) ) $_SESSION["origURL"] = $_SERVER["HTTP_REFERER"]; 回答2: As Johnathan Suggested, you would either want to save it in a cookie or a session.

Will a 302 redirect maintain the referer string?

a 夏天 提交于 2019-11-26 03:09:29
问题 I need to redirect the user from one page to another, but I need to maintain the original referer string. So, for example, if they start out on http://www.othersite.com/pageA.jsp, click a link that takes them to http://www.mysite.com/pageB.jsp, which then executes a 302 redirect to http://www.mysite.com/pageC.jsp, I need the referer string to contain \"http://www.othersite.com/pageA.jsp\" Is this the normal behavior for a 302 redirect? Or would my original referer get dropped, in favor of \

Getting the HTTP Referrer in ASP.NET

无人久伴 提交于 2019-11-26 00:48:18
问题 I\'m looking for a quick, easy and reliable way of getting the browser\'s HTTP Referrer in ASP.Net ( C# ). I know the HTTP Referrer itself is unreliable, but I do want a reliable way of getting the referrer if it is present. 回答1: You could use the UrlReferrer property of the current request: Request.UrlReferrer This will read the Referer HTTP header from the request which may or may not be supplied by the client (user agent). 回答2: Use the Request.UrlReferrer property. Underneath the scenes it