how to create a backup of a file once the current one is changed using php

Posted by SkyLar on Stack Overflow See other posts from Stack Overflow or by SkyLar
Published on 2009-06-05T23:18:04Z Indexed on 2010/05/28 9:01 UTC
Read the original article Hit count: 202

Filed under:

I'm playing around with file info in php and i'm wondering if its possible to do the following:

once a file is changed get the contents of the file, then put the contents of the file into another file.

kinda like a "backup system" so once you make a change to the file a duplicate one is created, each change to the original file overwrites the duplicate one.

i'm trying to do this with storing the time in the db, is this possible? i don't know what there is to test against?

more clearly, i would like to do the following: execute a script once a specifeced file is changed on the server

© Stack Overflow or respective owner

Related posts about php