Ticket #1934: wp-db-backup.diff
| File wp-db-backup.diff, 1.7 KB (added by skippy, 7 years ago) |
|---|
-
wp-db-backup.php
19 19 20 20 $rand = substr( md5( md5( DB_PASSWORD ) ), -5 ); 21 21 22 define('WP_BACKUP_DIR', 'wp-content/backup -' . $rand);22 define('WP_BACKUP_DIR', 'wp-content/backup/' . $rand); 23 23 24 24 define('ROWS_PER_SEGMENT', 100); 25 25 … … 739 739 if ( @ mkdir( ABSPATH . $this->backup_dir) ) { 740 740 @ chmod( ABSPATH . $this->backup_dir, $dir_perms); 741 741 } else { 742 echo '<div class="updated error"><p align="center">' . __('WARNING: Your wp-content directory is <strong>NOT</strong> writable! We can not create the backup directory.', 'wp-db-backup') . '<br />' . ABSPATH . "</p></div>"; 742 echo '<div class="updated error"><p align="center">' . __('WARNING: Your <code>/wp-content/backup/</code> directory is <strong>NOT</strong> writable! We cannot create the backup directory:', 'wp-db-backup') . '<br />' . ABSPATH . WP_BACKUP_DIR . "</p></div>"; 743 die(); 743 744 $WHOOPS = TRUE; 744 745 } 745 746 } 746 747 747 748 if ( !is_writable( ABSPATH . $this->backup_dir) ) { 748 echo '<div class="updated error"><p align="center">' . __('WARNING: Your backup directory is <strong>NOT</strong> writable! We can not create the backup directory.', 'wp-db-backup') . '<br />' . ABSPATH. "</p></div>";749 echo '<div class="updated error"><p align="center">' . __('WARNING: Your backup directory is <strong>NOT</strong> writable! We cannot create the backup directory:', 'wp-db-backup') . '<br />' . ABSPATH . WP_BACKUP_DIR . "</p></div>"; 749 750 } 750 751 751 752 if ( !file_exists( ABSPATH . $this->backup_dir . 'index.php') ) { … … 880 881 881 882 $mywpdbbackup = new wpdbBackup(); 882 883 883 ?> 884 No newline at end of file 884 ?>
