|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
uploading??
im trying to get an upload feature to work... nothing spectacular of course:
here's the code for the output of a form: if ($superdat_name != "") { copy("$superdat", "/usr/local/psa/home/vhosts/springfieldam.fiyer.com/httpdocs/upload/$superdat_name") or die("Couldn't copy file."); } else { die("No input file specified."); } it wont upload tho! i dont know why. i get an error saying Warning: open_basedir restriction in effect. File is in wrong directory in /usr/local/psa/home/vhosts/springfieldam.fiyer.com/httpdocs/do_upload.php on line 4 any suggestions? |
|
#2
|
|||
|
|||
|
RE: uploading??
The server has turned the Save_Mode on, so the function copy() won't work, instead of copy() use move_uploaded_file();
when you want to upload files be sure you use enctype="multipart/form-data" into the form-tag. I.E. <form method=post action=blaat.php enctype=multipart/form-data> </form> |
|
#3
|
|||
|
|||
|
RE: uploading??
try using $_FILE['superdat']['tempname']
$_FILE['superdat']['name'] $_FILE['superdat']['size'] etc... |
|
#4
|
|||
|
|||
|
RE: uploading??
Your solution won't work.
You can only use move_uploaded_file(); |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PHP Coding > uploading?? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|
|
|