jronyagz Posted November 23, 2006 Share Posted November 23, 2006 hello guys,i just whant to know why this code did not save the image on the new DIR $upload_paths,it will only successfully create the folder but the image will not be saved. i hope smbody could enlighten me..thnx!if(is_dir($upload_path)) { $upload_paths =#mkdir($upload_path."24x24".'/', 0700);if(is_dir(mkdir($upload_paths)) { if ($_POST['type'] == 'image/pjpeg' || $_POST['type'] == 'image/gif' || $_POST['type'] == 'image/x-png' || $_POST['type'] == 'image/bmp' || $_POST['type'] == 'image/jpeg') { if ($_POST['type'] == 'image/pjpeg' || $_POST['type'] == 'image/jpeg') { $img=imagecreatefromjpeg($upload_paths.$_POST['name']); } elseif ($_POST['type'] == 'image/gif') { $img=imagecreatefromgif($upload_paths.$_POST['name']); } elseif ($_POST['type'] == 'image/x-png') { $img=imagecreatefrompng($upload_paths.$_POST['name']); } elseif ($_POST['type'] == 'image/bmp') { $img=imagecreatefromwbmp($upload_paths.$_POST['name']); }$AttachmentThumbnail->thumbnail($img,205,272,$upload_paths,$_POST['name'],205,272); } } } Link to comment https://forums.phpfreaks.com/topic/28260-help-saving-images-on-a-folderergent/ Share on other sites More sharing options...
jronyagz Posted November 23, 2006 Author Share Posted November 23, 2006 sorry ( $upload_paths =(#)mkdir($upload_path."24x24".'/', 0700);) change to this$upload_paths =mkdir($upload_path."24x24".'/', 0700); Link to comment https://forums.phpfreaks.com/topic/28260-help-saving-images-on-a-folderergent/#findComment-129250 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.