2

Perhaps I misunderstand how request.referrer works, but isn't it suppose to provide you with the url of the page the user is coming from? So for instance, if they're viewing an article and then click edit, their request might look like this:

request.referrer = http://localhost:3000/article/1
request.url = http://localhost:3000/article/1/edit

If that's the case, then I'm getting odd behaviour, because the user's request.referrer is always set to the current url. What might be causing this? It's worth noting that I'm using an AJAX powered site, and all these requests are remote.

4

1 回答 1

0

request.referrer应该是您发出请求的 URL,如果您使用 AJAX,我认为您应该更改您的 URL,以便您的推荐人更改。

于 2013-05-19T04:17:20.920 回答