ik heb een hosting die heeft php op safe modus draaien, nou lukt het uploaden niet meer 
als ik $bestand echo zie ik dit: /tmp/php0dxjHo
en $bestand_naam ziet er zo uit: 1496362668.gif (dat klopt, ik wou die file uploaden)
Warning: open_basedir restriction in effect. File is in wrong directory in /usr/local/*******/home/vhosts/*******/httpdocs/******/upload/upload.php on line 4
Bestand '1496362668.gif' met de grootte: 15626 bytes is succesvol geupload!
regel 4 is dus de copy regel.
wat doe ik nou fout?
owja ik kon niet echt veel zinnigs vinden met de search, wel upload scripts, maar die werken ook niet.
PHP:
1
| <?if ($submit) { if (is_uploaded_file($bestand)) { copy($bestand, "files/$bestand_name"); echo "Bestand '$bestand_name' met de grootte: $bestand_size bytes is succesvol geupload!"; } else { echo "Er is een fout bij het uploaden van bestand: '$bestand'!"; }}else { echo "<form method=\"post\" enctype=\"multipart/form-data\"> <div align=\"center\"> <p> <input type=\"file\" name=\"bestand\"> <br> <input type=\"submit\" value=\"Uploaden\" name=\"submit\"> </p> </div></form>";}?> |
als ik $bestand echo zie ik dit: /tmp/php0dxjHo
en $bestand_naam ziet er zo uit: 1496362668.gif (dat klopt, ik wou die file uploaden)
Warning: open_basedir restriction in effect. File is in wrong directory in /usr/local/*******/home/vhosts/*******/httpdocs/******/upload/upload.php on line 4
Bestand '1496362668.gif' met de grootte: 15626 bytes is succesvol geupload!
regel 4 is dus de copy regel.
wat doe ik nou fout?
owja ik kon niet echt veel zinnigs vinden met de search, wel upload scripts, maar die werken ook niet.