PHPjabbers - tools for webmasters
shopping cart (0 item)
HOME
PRODUCTS
PHP TUTORIALS
PHP FORUM
ABOUT US
CONTACT US
Our products

php upload and overwrite existing file

Posted by vikram on Jul 2nd, 2007

I want to know this thing when we upload the file on the server if there is another file already save with the same name and i want to replace that file with the new file can i do this. In short i want to replace the old file with the new file.

Back
REPLIES
Posted by sdfsdf on Apr 26th, 2011

test
Posted by Mark on Feb 24th, 2011

you can change file permissions using PHP after uploading the file.
Posted by edin on Feb 21st, 2011

Posted by Veselin Stoilov on Jul 2nd, 2007

when you upload the file for first time make sure to change its permissions so it is writable. Next time you upload a file with the same name it will overwrite the existing one.
______

So, every time when I want to upload "double" file on server, first should I go to root of server and change files permission??? Is that solution???
Posted by d on Jul 20th, 2010

asda
Posted by Veselin Stoilov on Jul 2nd, 2007

when you upload the file for first time make sure to change its permissions so it is writable. Next time you upload a file with the same name it will overwrite the existing one.
 
POST A REPLY
Your name:
Your email: (email address will not be posted on the website)
Reply:
Verification code:
type characters on the image in the text box