/    Sign up×
Community /Pin to ProfileBookmark

Cant uppload files IIS

Hi I am running a IIS server on an XP pro machine.

When I try to upload a file to a folder i manualy (the script does not seem to have the necessary premistions to create an directory) created I get an error saying:

change permission to 777 failed.

it is this peace of code that give´s me the error.

[CODE] $result = move_uploaded_file($temp_name, $file_path);
if (!chmod($file_path,0777))
$message = “change permission to 777 failed.”;[/CODE]

I have given it all access I can think of, but when I check the attributes in explorer it says read-only. But in command prompt with the attrib command it only returns the “S” attribute.

I have been able to upload one file yesterday but something happened and I no longer can upload.

what is wrong?

// Fredrik

to post a comment
PHP

4 Comments(s)

Copy linkTweet thisAlerts:
@aussie_girlJan 07.2007 — chmod xxx is only for unix/linux machines, you need to set permissions by right clicking on the folder and giving the necessary user the proper permissions
Copy linkTweet thisAlerts:
@fredrikauthorJan 07.2007 — I know that, and I have given ALL users ALL privileges possible in an effort to be on the safe side.
Copy linkTweet thisAlerts:
@aussie_girlJan 07.2007 — through IIS or windows browser? have you ticked the box to allow annonymous access and specified account name? I'm using IISv6
Copy linkTweet thisAlerts:
@fredrikauthorJan 07.2007 — Yes I have checked the box anonymus acess and IIS had filled in the username IUSR_SHUTTLE (where shuttle is the name of my computer)

I have given acess trough both Windows browser and IIS.
------


I just tried to uppload a picture (.jpg) it worked!

But not a .WMV file not even if i rename it to .jpg. still get the 777 error. Uploading a .exe vill not work and it shuldent ither sins I have not allowed it in the script.

the question is now why does the script want to tamper with the attrubute on the wmv file but not the .jpg?

I´m using the upload script from: http://savasplace.com/page.php?page=PHP/MySQL_Web_Scripts
×

Success!

Help @fredrik spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.15,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...