首页文件与媒体FileDriver 高层封装
FileDriver 高层封装
Kuoqi\FileDriver(329 行):下载/输出/转码/另存
本页内容
  1. 方法清单
  2. 已知缺陷

方法清单

方法签名说明
copyFromfilecopyFromfile($filename)从文件复制
downloaddownload($filename="")Code200 响应头输出附件下载
flushTofileflushTofile()内容刷入文件
readAsconfigreadAsconfig()读为 ConfigFiledriver
readAsphpreadAsphp($args,$isOnce=false)include 渲染捕获输出
readAsJsonreadAsJson()读为 JSON 数组
saveAssaveAs($nfile)另存为
toImagetoImage()转为 Image 对象(空基类)
toJpgSource/toPngSource/toWebpSource()GD 资源
toWebptoWebp()转 WebP
formatBytesformatBytes($bytes)字节格式化

已知缺陷

readAscss/readAsmp4/readAsjs 引用不存在的 Reader 类;downloadWithRetry 内部调用 downloadLargeFile 未加 self::(PHP 会当未定义函数报错)。
KuoqiPHP v1.05 · 离线静态文档 · 界面基于 KuoqiUI · 返回首页