Not for 'how-to' coding questions but PHP theory instead, this forum is here for those of us who wish to learn about design aspects of programming with PHP.
but when i move the application to hosting server (example: http//www.mydomain.com/index.php) , the upload doesn't work, the error was the files which been chosen to be uploaded couldn't copy into directory ( directory created to store uploaded files in website root directory) in server. Is it because of the server doesn't allow someone to write file into directory or i don't have the permission to write file into directory? I couldn't catch the error that cause this uploading fail.....
Forum Rules wrote:Use descriptive subjects when you start a new thread. Vague titles such as "Help!", "Why?" are misleading and keep you from receiving an answer to your question.
Is there any error message being printed to the browser after you try uploading the file? You may need to change the directory's permissions to allow writing (I think its chmod 700).
first of all, sorry for the misleading topic been posted just now...
the error appear for sometimes only, which is change permisson to 0755 fail...but this error also appear during testing in local machine ( localhost) and the file still bein copy into the directory .....
Change your thread title please.... I don't particularly want to have to do it for you and right now nobdoy knows what your thread is about without reading it.
nickvd wrote:change the permissions for the directory in question to 777...
:s
755
How is apache going to write to a directory it does not have write permission to? Unless it's run in safe mode or suid it wont work... I would be nice if more hosts are configured to allow non 777 directories, but right now, that's not the case...
I have yet to see a host who configures things that way, hence the vast amount of documentation that (unfortunately) recommends writable directories being 777.
Don't get me wrong, I agree with you, I HATE having to set things to 755, but you do whacha gotta do.