大家好,可以帮我看看是什么问题吗?
通过input type="file" 获取的文件对象
在hbuilder里是
{"0":{"webkitRelativePath":"","lastModifiedDate":"2015-07-24T09:16:25.000Z","name":"76337","type":"","size":1501151},"length":1}
而在普通网页下获取到的对象是
{"0":{"webkitRelativePath":"","lastModified":1417070767594,"lastModifiedDate":"2014-11-27T06:46:07.594Z","name":"Screenshot_2014-11-26-13-29-06.png","type":"image/png","size":285349},"length":1}
在hbuilder里的name和type都不正确呢?
1 个回复
z***@foxmail.com
同问!参照uploader demo,只能上传拍照图片和plus.gallery.picker,不能上传input type='file'的文件。一个APP应有多种上传文件的方法,不只是上传image。如果h5+有普通文件的picker,再加上uploader demo就完美了