QINIU_FUNCTIONS_VERSION
QINIU_FUNCTIONS_VERSION = \Qiniu\Config::SDK_VER
json_decode(string $json, boolean $assoc = false, integer $depth = 512) : mixed
Wrapper for JSON decode that implements error detection with helpful error messages.
string | $json | JSON data to parse |
boolean | $assoc | When true, returned objects will be converted into associative arrays. |
integer | $depth | User specified recursion depth. |
if the JSON cannot be parsed.
thumbnail(string $url, integer $mode, integer $width, integer $height, string $format = null, integer $quality = null, integer $interlace = null, integer $ignoreError = 1) : string
缩略图链接拼接
string | $url | 图片链接 |
integer | $mode | 缩略模式 |
integer | $width | 宽度 |
integer | $height | 长度 |
string | $format | 输出类型 |
integer | $quality | 图片质量 |
integer | $interlace | 是否支持渐进显示 |
integer | $ignoreError | 忽略结果 |
waterImg(string $url, string $image, \Qiniu\numeric $dissolve = 100, string $gravity = 'SouthEast', \Qiniu\numeric $dx = null, \Qiniu\numeric $dy = null, \Qiniu\numeric $watermarkScale = null) : string
图片水印
string | $url | 图片链接 |
string | $image | 水印图片链接 |
\Qiniu\numeric | $dissolve | 透明度 |
string | $gravity | 水印位置 |
\Qiniu\numeric | $dx | 横轴边距 |
\Qiniu\numeric | $dy | 纵轴边距 |
\Qiniu\numeric | $watermarkScale | 自适应原图的短边比例 |
waterText(string $url, string $text, string $font = '黑体', string $fontSize, string $fontColor = null, \Qiniu\numeric $dissolve = 100, string $gravity = 'SouthEast', \Qiniu\numeric $dx = null, \Qiniu\numeric $dy = null) : string
文字水印
string | $url | 图片链接 |
string | $text | 文字 |
string | $font | 文字字体 |
string | $fontSize | 文字字号 |
string | $fontColor | 文字颜色 |
\Qiniu\numeric | $dissolve | 透明度 |
string | $gravity | 水印位置 |
\Qiniu\numeric | $dx | 横轴边距 |
\Qiniu\numeric | $dy | 纵轴边距 |