![]() |
|
Welcome to the Computer Webmaster Gaming Console Graphics Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
| |||||||
| PHP PHP for some can be one of the hardest website programming codes, so do you need help on your PHP script, if it is php4, php5 or lower this is the place for you for any PHP help. |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| | #1 | ||
| i have an auction web site and in the gallary section people can upload more then 1 picture but the files are being uploaded as per 600(chmod) and they need to be 644 or 755. I'v put the part of the php texted that i think needs editing below. #// PROCESS UPLOADED FILE if($HTTP_POST_VARS[uploadpicture] == $MSG_681) { if(!empty($HTTP_POST_FILES[userfile][tmp_name]) && $HTTP_POST_FILES[userfile][tmp_name] != "none") { if($HTTP_POST_FILES[userfile][size] > ($SETTINGS[maxpicturesize] * 1024)) { $ERR = $ERR_709." ".$SETTINGS[maxpicturesize]." Kbytes"; } elseif(!strpos($HTTP_POST_FILES[userfile][type],"gif") && !strpos($HTTP_POST_FILES[userfile][type],"png") && !strpos($HTTP_POST_FILES[userfile][type],"jpeg")) { $ERR = $ERR_710."(".$HTTP_POST_FILES[userfile][type].")"; } else { #// Create a TMP directory for this session (if not already created) if(!file_exists($image_upload_path.session_id())) { mkdir($image_upload_path.session_id(),0777); } #// Move uploaded file into TMP directory move_uploaded_file($HTTP_POST_FILES[userfile][tmp_name], $image_upload_path.session_id()."/".$HTTP_POST_FILES[userfile][name]); #//Populate arrays $UPLOADED_PICTURES[] = $HTTP_POST_FILES[userfile][name]; $UPLOADED_PICTURES_SIZE[] = $HTTP_POST_FILES[userfile][size]; session_name($SESSION_NAME); session_register(UPLOADED_PICTURES,UPLOADED_PICTUR ES_SIZE); ##-----------------------------------------------## Article posted from PHP Freaks NewsGroups http://www.phpfreaks.com/newsgroups Get Addicted: alt.php ##-----------------------------------------------## | |||
| Featured Websites | ||||
|
![]() |
| Tags: 600, 644, changing, permissions, php, upload |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| php upload script | Stijn De Moor | PHP | 4 | 07-01-2007 3:40 PM |
| Upload | Frank | HTML | 1 | 07-01-2007 2:01 PM |
| Help, cannot upload maps on map330 | Ian | GPS | 0 | 06-25-2007 11:23 PM |
| Upload to computer | Tim Sperry | GPS | 2 | 06-12-2007 5:13 PM |
| MySQL permissions | toffee | Database | 4 | 06-10-2007 12:25 AM |
| Featured Websites | ||||
|