如何使用 Google Analytics 跟踪我的 WordPress 点击率?

发布于 2024-11-13 11:58:13 字数 965 浏览 4 评论 0原文

我正在使用 ANALYTICACTOR 插件来跟踪我的页面点击率,它似乎完全按照需要执行的操作,它将其代码放置在每个页面上。我想知道的是,下面的代码是否有问题,或者我的帐户设置是否错误,因为它要么必须是此代码,要么我的帐户设置不正确。谷歌曾一度追踪到我网站的八次点击,但现在我不知道为什么它不再这样做了。任何帮助将不胜感激,如果一切顺利,我会通过电子邮件给您发送原始剧本,如果您只是尝试,我什至会通过电子邮件给您发送剧本,因为我不会写代码。

我的网站包含完整的 html 代码,位于 http://www.knowledgenation.us


var analyticsFileTypes = [''];
var analyticsEventTracking = 'enabled';

var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-21764875-1']);
pub-4733510614502996
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();

I am using the ANALYTICACTOR plug in to track my page hits and it seems to do exactly what it needs to be doing, it places its code on every page. What I want to know is , is there something wrong with the code below or could I have my account set up wrong because it either has to be this code or my account settings are not correct. Google did track eight hits to my website at one point and now I do not know why it has stopped doing so. Any help would be appreciated and I will email you an original screenplay if things go well, ill even email you a screenplay if you just try becuse I write i cant code.

my website with the fully html code is at http://www.knowledgenation.us

var analyticsFileTypes = [''];
var analyticsEventTracking = 'enabled';

var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-21764875-1']);
pub-4733510614502996

_gaq.push(['_trackPageview']);

(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

百思不得你姐 2024-11-20 11:58:13

您的页面实际上有两次对 Google Analytics 的调用。页面底部还有另一个将数据发送到 UA-23607774-1 帐户的操作。它工作正常并发送数据,但您上面发布的代码片段报告错误并且无法正确跟踪。带有 pub-4733510614502996 的行是问题所在,需要删除。我猜它位于 Google 分析器设置的附加跟踪代码(跟踪器初始化之前) 字段中。

Your page actually has two calls to Google Analytics. There's another one at the bottom of the page that sends data to the UA-23607774-1 account. That's working correctly and sending data but the code snippet you've posted above is reporting an error and not tracking properly. The line with pub-4733510614502996 is the problem and needs to be removed. I'm guessing it's located in the Additional tracking code (before tracker initialization) field of the Google Analyticator settings.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文