PHPackages                             reaway/think-request - 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. reaway/think-request

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

reaway/think-request
====================

think request

v1.0.4(3y ago)0261Apache-2.0PHPPHP &gt;=7.2.0

Since Feb 4Pushed 3y ago1 watchersCompare

[ Source](https://github.com/reaway/think-request)[ Packagist](https://packagist.org/packages/reaway/think-request)[ Docs](https://github.com/reaway/think-request)[ RSS](/packages/reaway-think-request/feed)WikiDiscussions main Synced 6d ago

READMEChangelog (5)Dependencies (5)Versions (6)Used By (1)

think-request
=============

[](#think-request)

安装
--

[](#安装)

```
composer require reaway/think-request
```

用法
--

[](#用法)

```
use Think\Component\Request\Facade\Request;

require __DIR__ . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';

Request::has('id','get');
Request::has('name','post');
Request::param('name');
Request::get('name'); // 返回值为null

// 判断变量是否定义
input('?get.id');
input('?post.name');

// 获取PARAM参数
input('param.name'); // 获取单个参数
input('param.'); // 获取全部参数
// 下面是等效的
input('name');
input('');

// 获取GET参数
// 获取单个变量
input('get.id');
// 使用过滤方法获取 默认为空字符串
input('get.name');
// 获取全部变量
input('get.');

// 使用过滤方法
input('get.name','','htmlspecialchars'); // 获取get变量 并用htmlspecialchars函数过滤
input('username','','strip_tags'); // 获取param变量 并用strip_tags函数过滤
input('post.name','','org\Filter::safeHtml'); // 获取post变量 并用org\Filter类的safeHtml方法过滤

// 使用变量修饰符
input('get.id/d');
input('post.name/s');
input('post.ids/a');
```

文档
--

[](#文档)

详细参考 [请求](https://www.kancloud.cn/manual/thinkphp6_0/1037519)

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity48

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

Total

5

Last Release

1293d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d342ebe348631bdfbe41ebcd414f0b5fa2334027d413e3543afb301f3503a13f?d=identicon)[reaway](/maintainers/reaway)

---

Top Contributors

[![reaway](https://avatars.githubusercontent.com/u/60423559?v=4)](https://github.com/reaway "reaway (10 commits)")

### Embed Badge

![Health badge](/badges/reaway-think-request/health.svg)

```
[![Health](https://phpackages.com/badges/reaway-think-request/health.svg)](https://phpackages.com/packages/reaway-think-request)
```

PHPackages © 2026

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