|
|
@ -187,8 +187,9 @@ Class ApiController extends Controller { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
try { |
|
|
|
$res = mkdir("{$target}/{$newDir}"); |
|
|
|
$res = mkdir("{$target}/{$newDir}", 0775); |
|
|
|
if ($res) { |
|
|
|
if ($res) { |
|
|
|
|
|
|
|
chmod("{$target}/{$newDir}", 0775); |
|
|
|
$code = 1; |
|
|
|
$code = 1; |
|
|
|
$msg = '目录创建完成'; |
|
|
|
$msg = '目录创建完成'; |
|
|
|
}else { |
|
|
|
}else { |
|
|
@ -581,6 +582,7 @@ Class ApiController extends Controller { |
|
|
|
$base64 = str_replace(' ', '+', $base64); |
|
|
|
$base64 = str_replace(' ', '+', $base64); |
|
|
|
$fileContent = base64_decode($base64); |
|
|
|
$fileContent = base64_decode($base64); |
|
|
|
file_put_contents($filePath, $fileContent); |
|
|
|
file_put_contents($filePath, $fileContent); |
|
|
|
|
|
|
|
chmod($filePath, 0664); |
|
|
|
|
|
|
|
|
|
|
|
//判断文件大小 |
|
|
|
//判断文件大小 |
|
|
|
$maxLength = FSC::$app['config']['admin']['maxUploadFileSize'] * 1024*1024; |
|
|
|
$maxLength = FSC::$app['config']['admin']['maxUploadFileSize'] * 1024*1024; |
|
|
|