Php Easy File Upload
Although actually easier to upload files to the server with php, loading file server and image resizing dosyalası constitute a danger to the server instead of a laborious process to prevent the installation files.
class.upload on this issue prepared by verot.net distress grows. class.upload our behalf proportionally scales the image files, the file is able to check whether you really picture. Turkish translation of the features available in the next class.upload. error alerts, so that you can see in Turkish.
both 160px wide and 640px have prepared wide sunucya example, the file will be installed. If you only need the file and upload it into a huge and lines beginning with $ h2 $ foldersmall created by deleting the line that begins with the loading of the file system can provide just great.
Sample code that we class.upload for use;
$ h1 = new Upload ( $ _FILES [ 'file'] , ' en_US '); $ h1 -> file_safe_name = true; // system file name characters that are not appropriate will be deleted $ h1 -> image_resize = true; // Photo Resize $ h1 -> image_ratio_y = true; // get the average image size $ h1 -> image_x = 640; / / image width in px $ h1 -> image_ratio_fill = true; // if the image does not match the values given in the remaining part of the fill it with white color $ h1 -> image_convert = 'jpg ' // Convert image format jpg $ h1 -> allowed = array (' image / * '); // only accept image files $ h1 -> forbidden = array ( 'application / * '); // to accept any application file $ h1 -> file_overwrite = true; / / add pictures if you have the same Overwrite $ h1 -> file_new_name_body = $ rand ; // new file name ... automatically provided a numerical example, the creation of value . $ h1 -> Process ( $ folderbig ); // save the file and folder