This is an archived forum post. The information may be outdated. Contact us if you have any questions.

What is the referer when using Save to PDF link?

brianz wrote on 2011-05-30:
I have a secured site I'd like to allow access to pdfcrowd for the Save to PDF link to bypass the login screen.

I want to use PHP to check the referer and allow the request coming from pdfcrowd to bypass login, what would I put as the referer?

So the code would be:

if ($_SERVER['http_referer'] == 'source of pdfcrowd request goes here') {
//code to bypass login goes here
}

Question is what is the source of the pdfcrowd request?

Thanks!
support wrote on 2011-05-30:
The referrer is a generic one:
Mozilla/5.0 (X11; U; Linux; en-US) AppleWebKit/531.2 (KHTML, like Gecko) Safari/531.2

So you may want to check the IP as well: 207.126.122.174
brianz wrote on 2011-06-25:
Wonderful thanks! :)
quotientapp wrote on 2012-03-31:
I'd like to make a request/suggestion, would you be able to add a unique header? Such as:

Via:Pdfcrowd.com

I know it's not really being used to describe a proxy service as per the spec (see, http://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Responses ) but it could be something test-able that's guaranteed not to change in the future :)

Thanks for the excellent service, keep up the great work!
support wrote on 2012-04-01:
Thanks for the suggestion. We will be considering this for the future.