用于跟踪网页浏览量(或唯一访问者)的最佳 Grails 实现?

发布于 2024-09-26 22:36:03 字数 277 浏览 0 评论 0原文

我需要实现一个非常流行的功能:显示个人资料页面的浏览次数

例如,StackOverflow 中的我的个人资料页面将显示有多少人查看过我的个人资料(就在我的声誉分数下方)。

我认为该算法基于一些 cookie 和/或访问者 IP 地址。有没有一种简单的方法(插件或一些代码源)可以在 tomcat/apache 上运行的 Grails 中实现它?

I need to implement a very popular feature : displaying the number of views for a profile page.

For instance, my profile page in StackOverflow will display how many persons have viewed my profile (just under my reputation score).

I suppose that the algorithm is based on some cookies and/or visitor IP addresses. Is there a simple way (a plugin or some code source) to implement it in Grails running on tomcat/apache?

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

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

发布评论

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

评论(2

疯狂的代价 2024-10-03 22:36:03

查看 Clickstream 插件:http://grails.org/plugin/clickstream

我没有使用过它直接,但它基于我在 Grails 之外使用过的库。我们考虑在一个项目中使用该插件,我审查了实现,它看起来很可靠,但我最终离开了该项目。

这并不直接解决您的请求,但您可以查询它创建的表,或者借用它用于执行跟踪各个页面的专门实现的逻辑。

Check out the Clickstream plugin: http://grails.org/plugin/clickstream

I haven't used it directly but it's based on a library that I've used outside of Grails. We considered using the plugin for a project and I reviewed the implementation and it looked solid, but I ended up leaving the project.

This doesn't directly address your request but you could query the table that it creates, or borrow the logic that it uses to do a specialized implementation for tracking individual pages.

九厘米的零° 2024-10-03 22:36:03

你为什么不使用谷歌分析?

Why don't you use Google Analytics?

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