Jump to content

cann't get access to the server while uploading a photo


lexmoen

Recommended Posts

I try to make a possibility to upload photo's from my website to the hostserver. should be easy, but i get a forbidden reaction

 

the page is:

 

 

<FORM ENCTYPE="multipart/form-data" ACTION="upload" METHOD=POST>
Upload: <INPUT NAME="userfile" TYPE="file">
<INPUT TYPE="submit" VALUE="verstuur foto"></FORM>
<?php
if ($userfile_size >250000){$msg=$msg."the foto is groter dan 250kb. Bezoek de help-pagina om te zien hoe de file verkleind kan worden.<BR>";
$file_upload="false";}

if (!($userfile_type =="image/pjpeg" OR $userfile_type=="image/gif")){$msg=$msg."foto's moeten van het formaat jpg of gif zijn.<BR>";
$file_upload="false";}

$add="upload/$userfile_name"; // the path with the file name where the file will be stored, upload is the directory name. 

if(move_uploaded_file ($userfile, $add)){
echo ('uploaden geslaagd.');
}

?>

 

 

and i get:

 

Forbidden

You don't have permission to access /upload/ on this server.

 

I made the map "upload" value 777, so that isn't the answer

 

what am i doing wrong?

 

thnaks

 

lex

Archived

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

×
×
  • Create New...

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.