utopia-php/analytics
最新稳定版本:0.15.1
Composer 安装命令:
composer require utopia-php/analytics
包简介
A simple library to track events & users.
README 文档
README
Utopia Analytics is a simple and lite library to send information about events or pageviews to various analytics platforms. This library is aiming to be as simple and easy to learn and use. This library is maintained by the Appwrite team.
Although this library is part of the Utopia Framework project it is dependency free and can be used as standalone with any other PHP project or framework.
Getting Started
Install using composer:
composer require utopia-php/analytics
Init in your application:
<?php require_once __DIR__ . '/../../vendor/autoload.php'; use Utopia\Analytics\GoogleAnalytics; $ga = new GoogleAnalytics("UA-XXXXXXXXX-X", "CLIENT-ID"); // Sends a pageview for `appwrite.io/docs/installation`. $ga->createPageView("appwrite.io", "/docs/installation"); // Sends an event indicating an installation. $ga->createEvent("Installation", "setup.cli"); // Sends an event indicating that the fall campaign promotional video was played. $ga->createEvent("Videos", "play", "Fall Campaign");
Supported Platforms
System Requirements
Utopia Framework requires PHP 7.4 or later. We recommend using the latest PHP version whenever possible.
Copyright and license
The MIT License (MIT) http://www.opensource.org/licenses/mit-license.php
统计信息
- 总下载量: 148.69k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 18
- 点击次数: 3
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-01-04