This article mainly introduces the sample code of CSS buried point statistics. The editor thinks it is quite good, so I will share it with you now and give it as a reference. Let’s follow the editor to take a look, I hope it can help everyone.
When the scale of a website or App reaches a certain level and it is necessary to analyze the corresponding operations of users in the App or website, it is necessary to focus on statistics of user behavior. Needless to say, the specific implementation requires writing JS scripts to bury the points. Event and adjustment interface, today I got a new way of tracking statistics, which is refreshing. The following code is a simple demonstration.
//index.html <!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" /> <title>CSS埋点</title> <style> .background { background-size: 100% 100%; width: 100%; height: 100%; position: fixed; z-index: -100; } html { background-color: #fff; } .notice-content { border: 1px #ccc solid; padding: 19px; border-radius: 10px; width: 80%; margin-left: 10%; margin-top: 10%; } .check-content { padding: 0!important; width: 80%!important; margin-left: 25px; margin-top: 10px; } .confirm { float: left; position: relative!important; left: 6%; height: 32px!important; line-height: 32px!important; } .btn { border: 1px solid #ff6689; background-color: #ff6689; width: 60%; margin-left: 20%; margin-top: 36px; font-size: 16px; font-weight: bold; color: #FFFFFF; } .title { display: block; text-align: center; font-size: 20px; margin-bottom: 19px; } span { display: block; margin-bottom: 7px; } .mui-checkbox input[type=checkbox]:checked:before, .mui-radio input[type=radio]:checked:before { color: #ff6689; } .body-content { width: 100%; height: 100%; } body { background-color: rgba(239, 239, 244, 0)!important; } .link:active::after{ margin: 100px 100px; color: red; content: url("http://192.168.1.100:8888/Hotels_Server/view/count.php?action=visit"); } </style> </head> <body> <p class="loading"> </p> <p class="body-content"> <p class="background"> <!-- <img src="/static/imghwm/default1.png" data-src="img/background.png" class="lazy" id="background" alt="Detailed explanation of CSS hidden statistics" > --> </p> <p class="notice-content"> <label class="title">登记须知</label> <span>1.本次登记仅限于中国地区。</span> <span>2.完成登记审核通过后,生育登记服务卡可到乡(镇、街道)直接领取,也可选择邮寄到付快递给申请人。</span> <span>3.申请登记信息需真实完整,如有虚假,申请人将承担相应的法律责任。</span> </p> <a class="link title">访问</a> </p> </body> </html>
//count.php <?php /** * Created by PhpStorm. * User: geek * Date: 2018/1/18 * Time: 上午9:56 */ $actionName = $_REQUEST["action"]; //时间格式化 $time = time(); $time = Date("Y-m-d",$time); echo "访问动作->" .$actionName. " 访问时间->" . $time; ?>
css click statistics
Related recommendations:
javascript - Website buried points, statistical user data
php implements word statistics function
The above is the detailed content of Detailed explanation of CSS hidden statistics. For more information, please follow other related articles on the PHP Chinese website!

Let's take a basic on-page link:

Websites have a tendency to decay all by themselves. Link rot, they call it. Unpaid domain name registrations. Companies that have gone out of business. Site

In a perfect world, our projects would have unlimited resources and time. Our teams would begin coding with well thought out and highly refined UX designs.

Oh, the Many Ways to Make Triangular Breadcrumb Ribbons

SVG has its own set of elements, attributes and properties to the extent that inline SVG code can get long and complex. By leveraging CSS and some of the forthcoming features of the SVG 2 specification, we can reduce that code for cleaner markup.

You might not know this, but JavaScript has stealthily accumulated quite a number of observers in recent times, and Intersection Observer is a part of that

We may not need to throw out all CSS animations. Remember, it’s prefers-reduced-motion, not prefers-no-motion.

PWA (Progressive Web Apps) have been with us for some time now. Yet, each time I try explaining it to clients, the same question pops up: "Will my users be


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

Dreamweaver Mac version
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

WebStorm Mac version
Useful JavaScript development tools