Dropzone.js-$ _FILES为空 [英] Dropzone.js - $_FILES is empty
本文介绍了Dropzone.js-$ _FILES为空的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有以下代码:
<form id="dvw-psa-enter-form" method="post" action="<?php echo site_url() . '/?upload' ?>" enctype="multipart/form-data">
<div class="dropzone">
<div class="fallback">
<input name="file" type="file" multiple />
</div>
</div>
<input type="submit" name="senden" />
</form>
<script src="<?php echo plugins_url() . '/dvelop-workflow-psa/dropzone.js' ?>"></script>
<script>
jQuery(".dropzone").dropzone({
url: "<?php echo plugins_url() . '/upload' ?>",
dictDefaultMessage: "Datei bitte hier ablegen!",
success: function() {
jQuery('.success-mark').show();
jQuery('.error-mark').hide();
},
error: function() {
jQuery('.success-mark').hide();
jQuery('.error-mark').show();
}
});
</script>
在我的php文件中$ _POST有一些信息,但是$ _FILES为空。
成功事件被触发:成功标记可见,但目录中没有文件,$ _ FILES为空。
in my php file $_POST has some informations, but $_FILES is empty. success event fired: success-mark is visible, but no file in directory and $_FILES is empty. With the classic variant, everthing is fine.
php.ini设置正确。
php.ini Settings are correct.
任何人都有一个主意。 ?
Anyone has an idea?
推荐答案
尝试在URL后面加上空格。当url为路径时,它将自动重定向到/ upload /,但清空$ _FILES数组。
Try the url with a trailing space. When the url is a path it will automaticly redirect to /upload/, but empty the $_FILES array.
这篇关于Dropzone.js-$ _FILES为空的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文