使用Google Analytics(分析)跟踪重定向页面 [英] track a redirect page with google analytics
问题描述
我试图使用google analytics来跟踪重定向页面:
我有一个名为 redirect.php
的页面;当我访问像 redirect.php?c = 12345678
这样的url时,php函数在sql查询表上执行查询来解码代码 12345678
,然后做一个 301
重定向。
做一个 例如: 显然,在Google Analytics中,我无法找到 是否有可能在某些方面跟踪每个重定向? 浏览器。无论何时用户通过GA脚本访问页面 - 都会发送用户向Google发送的关于访问的通知。 选项 当然,您可以合并这些选项,并说明一个包含元重定向和GA代码的页面,该页面会重定向到redirect.php脚本,该脚本又会转向301头,但这不是最好的解决方案。 I am trying to track a redirect page with google analytics: (I'm doing a For example: Obviously in Analytics I can't find the Is it possible to track every redirect in some ways? GA works in the browser. Whenever the user visits a page with the GA script - a request from the user to google is sent notifying about the visit.
Since you are making a 301 header redirect - no GA script is loaded and therefore google doesn't know the user has been on that page. Options you have Of course you could merge the options and have, say a page with meta redirect and the GA code, which redirects to redirect.php script, which in turn redirects with a 301 header, but this is not the best solution. 这篇关于使用Google Analytics(分析)跟踪重定向页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋! 301
重定向以避免重复的内容。)
我希望跟踪每一次访问 redirect.php $
redirect.php?c = 87654321
重定向到 story.php
。
redirect.php
页面。 story.php
referer是 organic / google
,所以我不能依赖引用者。
因为你正在做一个301头重定向 - 没有GA脚本加载,因此谷歌不知道用户已经在该页面上。
$ b
I have a page called redirect.php
; when I visit an url like redirect.php?c=12345678
, a php function does a query on a sql lookup table to decode the code 12345678
with a previously inserted url, then does a 301
redirect.301
redirect to avoid duplicate content.)
I wish to track every single visit to redirect.php
with analytics, but I can't.redirect.php?c=87654321
redirects to story.php
.redirect.php
page. the story.php
referer is organic/google
so I can't rely on the referer.