dropzone.js php 上传失败

dropzone.js php upload don't work

不幸的是我的“dropzone”不起作用,我遵循了这个教程:

http://www.startutorial.com/articles/view/how-to-build-a-file-upload-form-using-dropzonejs-and-php

我的订单结构与教程中提到的相同

好的,我有我的 index.php:

<html>

<head>   

<link rel="stylesheet/less" type="text/css" href="../css/style.less"/>
<script src="../scripts/less.js"> </script>
<script src="../scripts/dropzone.js"> </script>

</head>

<body>

<!-- 3 -->
<form action="upload.php" class="dropzone">

</form>

</body>

</html>>

upload.php:

<?php
$ds          = DIRECTORY_SEPARATOR;  //1

$storeFolder = 'uploads';   //2

if (!empty($_FILES)) {

    $tempFile = $_FILES['file']['tmp_name'];          //3             

    $targetPath = dirname( __FILE__ ) . $ds. $storeFolder . $ds;  //4

    $targetFile =  $targetPath. $_FILES['file']['name'];  //5

    move_uploaded_file($tempFile,$targetFile); //6

}
?>  

一切看起来都不错,只是我的上传文件夹中没有文件。 我没有错误,但我不确定我的错误报告是否正确。

感谢您的帮助

上面的代码工作正常。在意识到我的文件太大后,我开始工作了。