PHPackages                             qingbing/yii2-short-url - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. qingbing/yii2-short-url

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

qingbing/yii2-short-url
=======================

yii2实现的url短链系统组件

1.0.2(4y ago)02MITPHPPHP ^7.1.0

Since Dec 2Pushed 4y ago1 watchersCompare

[ Source](https://github.com/qingbing/yii2-short-url)[ Packagist](https://packagist.org/packages/qingbing/yii2-short-url)[ Docs](http://www.phpcorner.net)[ RSS](/packages/qingbing-yii2-short-url/feed)WikiDiscussions main Synced 3w ago

READMEChangelogDependencies (7)Versions (3)Used By (0)

yii-short-url
=============

[](#yii-short-url)

yii实现的url短链系统

1.该系统使用，需要设置
------------

[](#1该系统使用需要设置)

```
// 客户短链系统访问时的终端地址
Yii::$app->params['baseUrlForShortUrl']
```

2.短链的后台管理控制器可以直接引用
------------------

[](#2短链的后台管理控制器可以直接引用)

```
\YiiShortUrl\controllers\ShortUrlController

```

3.网页前台使用
--------

[](#3网页前台使用)

```
# 添加URL使用
\YiiShortUrl\logics\LogicShortUrl::getInstance()->add($params);

# 对于访问短链，提供action: \YiiShortUrl\actions\RedirectAccess
```

4. 配置参数
-------

[](#4-配置参数)

### 4.1 main.php

[](#41-mainphp)

```
'params'     => [
    'baseUrlForShortUrl' => define_var('PARAM_BASE_URI_FOR_SHORT', 'http://www.phpcorner.net/s'),
],
```

### 4.2 define-local.php

[](#42-define-localphp)

```
// 短链系统访问baseUri
defined('PARAM_BASE_URI_FOR_SHORT') or define('PARAM_BASE_URI_FOR_SHORT', 'http://www.phpcorner.net/s');
```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 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 ~45 days

Total

2

Last Release

1627d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/33932784?v=4)[qingbing](/maintainers/qingbing)[@qingbing](https://github.com/qingbing)

---

Top Contributors

[![qingbing](https://avatars.githubusercontent.com/u/33932784?v=4)](https://github.com/qingbing "qingbing (11 commits)")

---

Tags

urlphpyiishort urlyii-short-url

### Embed Badge

![Health badge](/badges/qingbing-yii2-short-url/health.svg)

```
[![Health](https://phpackages.com/badges/qingbing-yii2-short-url/health.svg)](https://phpackages.com/packages/qingbing-yii2-short-url)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M3.1k](/packages/craftcms-cms)

PHPackages © 2026

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