I need a function that shows me the url of the origin of the visitor of my page. I've already tried $_SERVER['HTTP_REFERER']
, but it seems to only work when the source comes from a clicked link.
Currently working with an affiliate system, which sends clients to my site through links created by the system itself (Before actually being directed to my site, the customer goes through the affiliate program server, in order to register that customer and in the case of a sale made, the affiliate system pays the commissions due.)
I'm taking my platform out of this affiliate system, but since you already have many affiliate links posted on the internet, I'd like to take advantage of those links so you do not lose sales.
An example of an affiliate link is link
As I will no longer use this system, I would like my page to recognize that the visitor is coming from this link
/ url
. So that I can know who the affiliate is pointing to this visitor.