layui/docs/upload/examples/form.file.md

19 lines
408 B
Markdown
Raw Normal View History

2023-04-24 08:42:47 +08:00
<input type="file" name="file" id="ID-upload-demo-form-files">
2023-05-03 17:17:39 +08:00
<!-- import layui -->
2023-04-24 08:42:47 +08:00
<script>
layui.use(function(){
var upload = layui.upload;
var layer = layui.layer
// 渲染
upload.render({
elem: '#ID-upload-demo-form-files',
url: '', // 此处配置你自己的上传接口即可
done: function(res){
layer.msg('上传成功');
console.log(res)
}
});
});
</script>