In this material, I offer the code of my script " Php load handler
several images to the server " and a short description of its operation.
And try to upload your images using my script.
Below the page is the code of this script.
Script retrieves data from the form and the form code from the link.
Each form input passes data with its own variable, since the array is only
needed for multiple downloads with a single input with the multiple attribute,
as in parentheses (<input type="file" name="file[]" multiple>).
Script it has several types of checks for the reason for running the script
(against hacking attempts):
1) checking the address - where the script was launched from.
2) Captcha-protection not only from bots, but also attempts to circumvent our form.
3) from attempts-filling out the form, enter the program code.
4) Function "is_uploaded_file", checking whether the file was actually uploaded
using the "post" method, so that you can't copy it using our script,
some file that is not allowed to view, from your server.
Checks the file size - if it is larger than allowed, the file is skipped,
and the script continues to work.
Checking the file type.
When loading , the script creates a unique file name, for which it
is necessary translates the initial name from Cyrillic to Latin (the translate
function, not the author functions, but in this case it is very useful and I use it).
The resulting script adds a unique code and name
the image becomes unique.
Next, the script saves the file to your folder by copying it from
the temporary one. And so on the cycle, until all files are uploaded.
Try the script " Php handler for uploading multiple images to the server "
while you are working, upload your images to the server and you will see them on
this page.
Your images will be saved for five minutes and will only be visible by your ip which
you had at the time of loading (there are no such restrictions in the script itself).
That is , if your ip changes with the page update, then your images will change to
you won't see the page.
Open the upload form
Here is the code itself:
// Php handler for uploading multiple images to the server
< ?php
// Checking the address - where the script was launched from.
header("Location: $otkuda"); // Returns to the page if the result is positive!
} else {
header("Location: /");
exit();
}
} else {
header("Location: /");
exit();
}
? >
The script is free and can be installed on any number of your sites,
but you can only distribute with the presence of a link to this site from the site
distributions. good Luck! Alexey.