PHPackages                             blue-nest-cloud/bnc-upload - 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. blue-nest-cloud/bnc-upload

ActiveLibrary

blue-nest-cloud/bnc-upload
==========================

Upload package for thinkphp

v2.1(4y ago)010MITPHPPHP &gt;=7.1.0

Since Jun 11Pushed 4y ago1 watchersCompare

[ Source](https://github.com/Jzh-thub/bnc_upload)[ Packagist](https://packagist.org/packages/blue-nest-cloud/bnc-upload)[ RSS](/packages/blue-nest-cloud-bnc-upload/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (5)Versions (8)Used By (0)

Upload
======

[](#upload)

安装
--

[](#安装)

> composer require blue-nest-cloud/bnc-upload

配置
--

[](#配置)

> 配置文件位于 `config/bncUpload.php`

### 使用方式

[](#使用方式)

> 使用前 请修改 UploadService中的 sys\_config 配置

> 初始化
>
> $upload = UploadService::init($type); $type:1本地 2:七牛云 3:阿里云 4:腾讯云
>
> $res = $upload-&gt;to($path)-&gt;validate()-&gt;move();
>
> $path 是指保存路径; validate() 是否开启校验;(如果是分片上传则无效);move()上传; stream()流上传

> 分片上传
>
> 参数:
>
> fileHash 文件唯一标识
>
> chunk 当前文件分片编号 (默认:0)
>
> chunks 总分片数 (默认:1)
>
> size 总大小
>
> filename 文件名 带后缀

### 下面写个例子

[](#下面写个例子)

```
class Index{

    public function index(Request $request)
    {
        $path = 'uploads'
        $upload = UploadService::init(1);
        $res    = $upload->to($path)->validate()->move('file');
        if (!$res)
            $errorInfo = $upload->getError();//内部错误信息
        else
            print_r((array)$res);
    }
}

```

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity51

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

Total

7

Last Release

1787d ago

Major Versions

v1.1.x-dev → v2.0.02021-06-16

### Community

Maintainers

![](https://www.gravatar.com/avatar/18be0a4a9d7b5cab20e5f886d8c9a3e1362b5188f6e4c625db8895e7091bc0e5?d=identicon)[Jzh-thub](/maintainers/Jzh-thub)

---

Top Contributors

[![Jzh-thub](https://avatars.githubusercontent.com/u/74651570?v=4)](https://github.com/Jzh-thub "Jzh-thub (10 commits)")

### Embed Badge

![Health badge](/badges/blue-nest-cloud-bnc-upload/health.svg)

```
[![Health](https://phpackages.com/badges/blue-nest-cloud-bnc-upload/health.svg)](https://phpackages.com/packages/blue-nest-cloud-bnc-upload)
```

###  Alternatives

[zhongshaofa/easyadmin

基于ThinkPHP6.0和layui的快速开发的后台管理系统。

6609.3k](/packages/zhongshaofa-easyadmin)

PHPackages © 2026

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