1

I'm caching my site and blocks but using the AJAXblocks module to load a dynamic module that I do NOT want cached after the cached page has already loaded. This works great, but now what I want is for that dynamic block to look at the $_SERVER['HTTP_REFERER']. Unfortunately when doing this via AJAX the referer is the page itself. I'm not very great with PHP but is there any easy way to look at the page's actual referer after loading this via AJAX?

1
  • No, browsers will stop you from doing this. See stackoverflow.com/questions/8231366/…. You could fudge something together with the session, but the fact that you're trying to rely on the referer in the first place means what you're doing could almost certainly be done in a better way. It's an unreliable bit of data and should really be ignored
    – Clive
    Jan 24, 2015 at 13:20

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.