Jump to content

Archived

This topic is now archived and is closed to further replies.

birdie

php upload :-(

Recommended Posts

hi, i have a really annoying problem with php and my IIS. i have ensured that all of my folders
are writeable so its got nothing to do with that

<?
$base = $_FILES['file']['tmp_name'];

if(move_uploaded_file(basename($base), $target_path))
{
echo "success";
}
else
{
echo "denied";
}

?>

Instead of "success" i get..

denied
Warning: Unknown: open(C:\PHP\sessiondata\sess_eee7e1e966af0cb54acda12f08d2dd2c, O_RDWR) failed: Permission denied (13) in Unknown on line 0

Warning: Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (C:\PHP\sessiondata) in Unknown on line 0



My php.ini file has..

session.save_path= C:\PHP\sessiondata


Any help would be greatly appreciated :-)p

Share this post


Link to post
Share on other sites
check your php.ini to make sure the setting are ok and that you are not exceeding the filesize also

;;;;;;;;;;;;;;;;
; File Uploads ;
;;;;;;;;;;;;;;;;

; Whether to allow HTTP file uploads.
file_uploads = On

; Temporary directory for HTTP uploaded files (will use system default if not
; specified).
upload_tmp_dir = C:\PHP\uploadtemp ; temporary directory for HTTP uploaded files (will use system default if not specified)

; Maximum allowed size for uploaded files.
upload_max_filesize = 2M

Share this post


Link to post
Share on other sites
[!--quoteo(post=380284:date=Jun 5 2006, 07:22 PM:name=jvrothjr)--][div class=\'quotetop\']QUOTE(jvrothjr @ Jun 5 2006, 07:22 PM) [snapback]380284[/snapback][/div][div class=\'quotemain\'][!--quotec--]
check your php.ini to make sure the setting are ok and that you are not exceeding the filesize also

;;;;;;;;;;;;;;;;
; File Uploads ;
;;;;;;;;;;;;;;;;

; Whether to allow HTTP file uploads.
file_uploads = On

; Temporary directory for HTTP uploaded files (will use system default if not
; specified).
upload_tmp_dir = C:\PHP\uploadtemp ; temporary directory for HTTP uploaded files (will use system default if not specified)

; Maximum allowed size for uploaded files.
upload_max_filesize = 2M
[/quote]
ok thanks

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.