Rails: is there a way to tell the source of the re

2020-04-06 00:57发布

问题:

Google analytics tells me what the source of my traffic is (search engines, facebook etc). Is there a way to get this information for each request from the request object or otherwise? I'd appreciate any help.

回答1:

request.referrer will give you the HTTP referrer value.