var $fileLinkInput = $('#file_link_full'); $fileLinkInput.fileinput({ language: 'zh', uploadUrl: '<?php echo Yii::$app->urlManager->createUrl(['file/image', 'type' => 'work_file']);?>', initialPreview: [defaultFile], initialPreviewAsData: true, initialPreviewFileType: 'pdf', allowedFileExtensions: ['docx', 'doc', 'pdf'], overwriteInitial: false, maxFileSize: 10000, maxFilesNum: 1, slugCallback: function (filename) { return filename.replace('(', '_').replace(']', '_'); } });
fileinput pdf编辑初始化预览
于 2024-09-10 10:09:23 首次发布