Home >Backend Development >PHP Tutorial >PHP Ajax upload file example [ajaxfileupload.js]_PHP tutorial
I have talked about using jquery ajax and php to upload images. Next, I will introduce how to use php ajax to upload various files without refreshing. I will give examples directly and hope it will be helpful to all students.
You can add and upload in batches, which is simple and convenient
The code is as follows | Copy code |
createUploadIframe: function(id, uri) }
}
createUploadForm: function(id, fileElementId, data) |
up_deal.php
代码如下
|
复制代码 | ||||
|| ($_FILES["file1"]["type"] == "image/jpeg")
}else { echo 'error';