Pro PHP Security From Application Security Principles to the Implementation of XSS Defenses by Unknown

Pro PHP Security From Application Security Principles to the Implementation of XSS Defenses by Unknown

Author:Unknown
Language: eng
Format: epub

Figure 11–1. File versioning by differences

A Realistic PHP Versioning System

The versioning system we will present is perhaps less efficient than an ideal one, but it is also far less complex, and so easier to get up and running: we are simply going to preserve the old version of a file by renaming it, and we'll then create a new version of the target file rather than update the old version. This can be carried out automatically at regular intervals (perhaps by a cron job), or manually as necessary (just before a heavy editing session, for example).

The following code fragment is a function to carry out such versioning. It can be found also as createVersionedBackup.php in the Chapter 11 folder of the downloadable archive of code for Pro PHP Security at http://www.apress.com .

<?php



Loading...
Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Web Analytics