Warning: copy(test.doc): failed to open stream: HTTP wrapper does not support writeable connections.
Is there a setting in php.ini I need to make in order for the copy() function to work properly, or is this the result of some server permission settings not allowing me to copy to that directory. I didn't think it was the latter seeing I could save files into that directory without a problem.
Here is my code:
Code: Select all
<?php
if ($File) {
print ("File Name: $file_name<br>");
print ("File Size: $file_size<br>");
if (copy ($File, "http://dev.usta.org/includes/$File_name")) {
print ("File was successfully uploaded.<br><br>");
} else {
print ("Sorry, file could not be uploaded.<br><br>");
}
unlink ($File);
} else {
print ("<strong>Upload a file to the filings server:</strong>");
print ("<FORM action="$PHP_Self" method="POST" ENCTYPE="multipart/form-data">");
?>
File: <input type="FILE" name="File" size=20 class="forms"> <input type="submit" name="submit" value="submit" class="forms">
</form><br>
<? } ?>