Я пытаюсь загрузить несколько файлов, используя uploadify, но каждый раз, когда я загружаю, в папке ничего нет.
Вот мой код
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Multiple files upload in PHP with using Uploadify!</title>
<!-- CSS -->
<link rel="stylesheet" href="uploadifyit/uploadify.css" type="text/css" />
<!-- Javascript -->
<script type="text/javascript" src="uploadifyit/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="uploadifyit/swfobject.js"></script>
<script type="text/javascript" src="uploadifyit/jquery.uploadify.v2.1.4.js"></script>
<script type="text/javascript">
$(document).ready(function() {
//alert('I am ready to use uploadify!');
$("#file_upload").uploadify({
'uploader': 'uploadifyit/uploadify.swf',
'script': 'uploadifyit/uploadify.php',
'cancelImg': 'uploadifyit/cancel.png',
'folder': 'uploads',
'auto': false, // use for auto upload
'multi': true,
'queueSizeLimit': 4,
'onQueueFull': function(event, queueSizeLimit) {
alert("Please don't put anymore files in me! You can upload " + queueSizeLimit + " files at once");
return false;
},
'onComplete': function(event, ID, fileObj, response, data) {
// you can use here jQuery AJAX method to send info at server-side.
$.post("insert.php", { name: fileObj.name }, function(info) {
alert(info); // alert UPLOADED FILE NAME
});
}
});
});
</script>
</head>
<body>
<form id="form1" name="form1" action="">
<input type="file" id="file_upload" name="file_upload" /><br />
<a href="javascript:$('#file_upload').uploadifyUpload();">Upload File</a>
</form>
</body>
</html>
Я не смог найти решение своей проблемы.
Кто-нибудь может мне помочь?
Заранее спасибо.