PHPackages                             mustang/footprint - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. mustang/footprint

ActiveLibrary

mustang/footprint
=================

thinkphp5.0 商城 '足迹' 基于redis的实现，可自行扩展其他存储介质。

v1.0.11(5y ago)1139MITPHP

Since Sep 17Pushed 5y ago1 watchersCompare

[ Source](https://github.com/SummerPassion/Footprint)[ Packagist](https://packagist.org/packages/mustang/footprint)[ RSS](/packages/mustang-footprint/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (1)Versions (13)Used By (0)

\#mustang/footprint

> "thinkphp5.0 商城足迹基于redis的实现，可自行扩展其他存储介质。

\##安装方法

```
composer require mustang/footprint

```

\##在项目中使用footprint

> V1.0版本仅更新了以Redis为存储介质的历史存取，后期可能扩展其他存储介质。 需要在config.php中配置以下信息

```
// redis相关配置
'redis' => [
    'host' => '127.0.0.1',
    'port' => 6379,
    'auth' => '',
    'db_id' => 0
]

// footprint 历史
'footprint' => [
    'driver' => 'redis',
    'max_len' => 80,
    // 热度排名
    'heat' => [
        'persist' => 1000, // 默认保留
        'del' => 100, // 满足长度后删除排名靠后的
    ],
    // 时序排名
    'seq' => [
        'persist' => 1000, // 默认保留
        'del' => 100, // 满足长度后保留从N位裁剪掉
    ]
]
```

**记录**

```
/**
 * 记录
 * @param string $val 记录纸
 * @param null $uid 用户标识
 * @param string|null $ord 排序
 * @param string|null $env 场景
 * @return bool|mixed
 */
Footprint::log($val, $uid = null, $ord = self::SEQ, $env = self::DEFAULT);
```

**获取**

```
/**
 * 获取历史
 * @param int $end 长度
 * @param null $uid 用户标识
 * @param string $ord 排序
 * @param string $env 场景
 * @return mixed|void
 */
Footprint::get($end, $uid = null, $ord = self::SEQ, $env = self::DEFAULT);
```

**分页获取**

```
/**
 * 分页获取
 * @param int $uid 用户id
 * @param int $page 第N页 N>0
 * @param int $pageSize 页面大小
 * @param string $env 场景
 * @param string $ord 排序
 */
Footprint::pageQuery($uid, $page=1, $pageSize=10, $env = self::DEFAULT, $ord = self::SEQ);
```

**清理**

```
/**
 * 清除历史
 * @param null $uid 用户标识
 * @param null $env 场景
 * @return mixed
 */
Footprint::clear($uid=null, $env=null);
```

**获取list长度**

```
/**
 * 获取list长度
 * @param int $end 长度
 * @param null $uid 用户标识
 * @param string $ord 排序
 * @param string $env 场景
 * @return mixed|void
 */
```

Footprint::getListLen($uid = null, $env = self::DEFAULT, $ord = self::SEQ)

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~33 days

Recently: every ~87 days

Total

12

Last Release

2068d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0b7ac7791e11761ebf23f119c8236b6762b12549e653237455caf725d684580d?d=identicon)[summerpassion](/maintainers/summerpassion)

---

Top Contributors

[![SummerPassion](https://avatars.githubusercontent.com/u/16045770?v=4)](https://github.com/SummerPassion "SummerPassion (13 commits)")

### Embed Badge

![Health badge](/badges/mustang-footprint/health.svg)

```
[![Health](https://phpackages.com/badges/mustang-footprint/health.svg)](https://phpackages.com/packages/mustang-footprint)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
