PHPackages                             blankphp/blankphp - 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. [Database &amp; ORM](/categories/database)
4. /
5. blankphp/blankphp

ActiveProject[Database &amp; ORM](/categories/database)

blankphp/blankphp
=================

The Blank Framework.

451PHP

Since Mar 21Pushed 4y agoCompare

[ Source](https://github.com/blankphp/BlankPhp)[ Packagist](https://packagist.org/packages/blankphp/blankphp)[ RSS](/packages/blankphp-blankphp/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (2)Used By (0)

[![BlankPhp.png](https://camo.githubusercontent.com/22ac59c2668c4ed92e2706f5dedbfa9e04ecd3d0e24ef803561489babff555aa/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30342f30382f356361616561383439656231662e706e67 "BlankPhp.png")](https://camo.githubusercontent.com/22ac59c2668c4ed92e2706f5dedbfa9e04ecd3d0e24ef803561489babff555aa/68747470733a2f2f692e6c6f6c692e6e65742f323031392f30342f30382f356361616561383439656231662e706e67)

[![996.icu](https://camo.githubusercontent.com/ac8f294a80f65338db545230f1a881b9a382204a1f187c6ff40ee679d42d40ca/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c696e6b2d3939362e6963752d7265642e737667)](https://996.icu)[![LICENSE](https://camo.githubusercontent.com/be80b8cb211ceb2263744e99fdb161a40124901906fd7c7f47d6361760dd7e8b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d416e74692532303939362d626c75652e737667)](https://github.com/996icu/996.ICU/blob/master/LICENSE)[![Build Status](https://camo.githubusercontent.com/5ea2742f409c4ef79cbb94e02d85c7fd9699eb8225ab5e7cd0d7d5b13bfbe5f0/68747470733a2f2f7472617669732d63692e6f72672f626c616e6b7068702f426c616e6b5068702e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/blankphp/BlankPhp)[![PHP Version](https://camo.githubusercontent.com/623cfd792d3446ada3cd9d470104811b54334be985e91588e51f49f627c957cc/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d372e322532422d626c75652e737667)](https://github.com/blankphp/BlankPhp)[![Version](https://camo.githubusercontent.com/03153134eb69d9587794dcd909334ebea6b2e228a1bbb5727e8c612f9bfe7953/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f76657273696f6e2d312e302e302d6c69676874677265792e737667)](https://github.com/blankphp/BlankPhp/releases)[![](https://camo.githubusercontent.com/4ec67cce7cac7a152fd08bc489e0795b86a2f4307b2020fa88c8e36b4b03b9c3/68747470733a2f2f706f7365722e707567782e6f72672f66617374642f66617374642f6c6963656e7365)](https://github.com/blankphp/BlankPhp)[![codecov](https://camo.githubusercontent.com/20a7d7537f549e0f6558fad640448467f1a530a2c563433820a44000a83cc7f4/68747470733a2f2f636f6465636f762e696f2f67682f626c616e6b7068702f426c616e6b5068702f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://codecov.io/gh/blankphp/BlankPhp)

#### 介绍

[](#介绍)

> 一个满足于基本开发的MVC轻量级框架`route` `IOC` `DB` `view` `middleware`已经设计完基本使用

1. 本框架意义在于理解IOC容器，以及依赖注入的思想
2. 本框架富含基本容器以及依赖注入
3. 框架具有路由以及中间件和基本orm功能，满足一个基本的快速开发概念
4. blankphp-swoole，blank-coolQ,blank-oauth2扩展正在书写中

    书写该框架的流程，以及遇到的问题，会整理出来！

#### 更新说明

[](#更新说明)

- 文档
- 容器
    - 依赖注入
    - 容器清理与重新注册
- 管道
    - 中间件
    - Pipeline扩展与异常
- 门面
    - 基本完成
    - 清理门面中的对象
- 服务提供者
    - register
    - boot
    - publish
- Session
    - RedisSessionHandler
    - FileSessionHandler
    - DatabaseSessionHandler
- Database
    - Builder
    - Grammar
    - Secure
- Cookie
- View
    - Builder
    - make
    - Diy
- 国际化
    - 国际化支持
- 安全
    - 验证码
    - 加密
    - xss
    - 防注入
- Swoole
    - Websocket
    - Process
    - Job
    - RPC
    - ...
- FormValidate
- Console
    - ConsoleKernel

#### 安装教程

[](#安装教程)

```
composer create-project blankqwq/blankphp:"dev-master"

```

参与开发
----

[](#参与开发)

[核心包](https://github.com/blankphp/framework)

> `php blank config:cache` 生成/更新配置文件

```
   root "/public";
    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }
//nginx配置好重写规则
```

#### 软件架构

[](#软件架构)

```
初步建设小型容器，满足基础的mvc服务，如何写出的会以文章形式公布
1.web路由在routes/web.php中注册
2.api路由在routes/api.php注册
3.中间件注册在MiddleWareProvider中注册
3.模型设计完成一部分，暂不支持多对多，一对多等关系

```

目录结构
----

[](#目录结构)

初始的目录结构如下：

```
├─app           应用目录
│  ├─Controllers         控制器目录
│  ├─Middleware          中间件目录
│  │  ├─StartSession.php      session启动中间件
│  ├─Models             模型目录
│  ├─Observer           模型观察者目录
│  ├─Provider           服务提供者目录
│
├─public                WEB目录（对外访问目录）
│  ├─index.php          入口文件
│  ├─static             静态目录
│  └─.htaccess          用于apache的重写
│
│
├─route                 路由注册目录
│  ├─web.php           web
│  ├─api.php           api
|
├─config                 配置文件目录
│  ├─app.php           核心配置
│  ├─db.php           数据库配置
|
│
├─cache                 缓存目录
├─resource              资源文件目录
├─vendor                第三方类库目录（Composer依赖库）
├─blank.php             命令行操作入口
├─composer.json         composer 定义文件
├─LICENSE               授权说明文件
├─README.md             README 文件

```

```

Server Software:        nginx
Server Hostname:        localhost
Server Port:            80

Document Path:          /
Document Length:        1326 bytes

Concurrency Level:      1000
Time taken for tests:   4.686 seconds
Complete requests:      10000
Failed requests:        113
   (Connect: 0, Receive: 0, Length: 113, Exceptions: 0)
Total transferred:      15581912 bytes
HTML transferred:       13110162 bytes
Requests per second:    2133.83 [#/sec] (mean)
Time per request:       468.641 [ms] (mean)
Time per request:       0.469 [ms] (mean, across all concurrent requests)
Transfer rate:          3246.99 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:       83  206  50.3    206     317
Processing:    51  248  61.9    247     481
Waiting:        0  173  58.0    175     315
Total:        206  454  75.6    459     698

Percentage of the requests served within a certain time (ms)
  50%    459
  66%    481
  75%    502
  80%    519
  90%    552
  95%    569
  98%    579
  99%    605
 100%    698 (longest request)

```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/1ad02fe5922d334a408f7ab3795fd0f4fbffd2fb436d66997c3ed2479e1c9b97?d=identicon)[blankqwq](/maintainers/blankqwq)

---

Top Contributors

[![blankqwq](https://avatars.githubusercontent.com/u/35186126?v=4)](https://github.com/blankqwq "blankqwq (97 commits)")

---

Tags

frameworkmvcmvc-frameworkormphp7

### Embed Badge

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

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

###  Alternatives

[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k117.2M118](/packages/jdorn-sql-formatter)[propel/propel1

Propel is an open-source Object-Relational Mapping (ORM) for PHP5.

8351.6M87](/packages/propel-propel1)[jfelder/oracledb

Oracle DB driver for Laravel

11518.4k](/packages/jfelder-oracledb)

PHPackages © 2026

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