reborn / reborn-upload
图片上传
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:think
Requires
- php: >=7.0
- topthink/think-installer: ^2.0
This package is auto-updated.
Last update: 2024-12-19 20:03:12 UTC
README
图片上传
demo
<?php
namespace app\index\controller;
use reborn\fileupload\FileUpload;
class Index
{
public function upload()
{
$file=(new FileUpload())->upload_local();
return $file;
}
}
html
<form action="/index/index/upload" enctype="multipart/form-data" method="post">
<input type="file" name="file" /> <br>
<input type="submit" value="上传" />
</form>