WP Staging – DB & File Duplicator & Migration - Version 1.0.6

Version Description

  • Fix: Uninstalling plugin throwing error
  • Fix: Error permission admin notice although permission issues are correct
Download this release

Release Info

Developer ReneHermi
Plugin Icon 128x128 WP Staging – DB & File Duplicator & Migration
Version 1.0.6
Comparing to
See all releases

Code changes from version 1.0.5 to 1.0.6

includes/admin/admin-notices.php CHANGED
@@ -25,12 +25,12 @@ function wpstg_admin_messages() {
25
26
if ( wpstg_is_admin_page() && !wp_is_writable( wpstg_get_upload_dir() ) ){
27
echo '<div class="error">';
28
- echo '<p><strong>WP Staging File Permission error: </strong>' . wpstg_get_upload_dir() . ' is not write and/or readable. <br> Check if the folder <strong>'.wpstg_get_upload_dir().'</strong> exists! File permissions should be chmod 755 or 777.</p>';
29
echo '</div>';
30
}
31
if ( wpstg_is_admin_page() && !wp_is_writable( WPSTG_PLUGIN_DIR . 'logs' ) ){
32
echo '<div class="error">';
33
- echo '<p><strong>WP Staging File Permission error: </strong>' . WPSTG_PLUGIN_DIR . 'logs' . ' is not write and/or readable. <br> Check if the folder <strong>'.WPSTG_PLUGIN_DIR . 'logs'.'</strong> exists! File permissions should be chmod 755 or 777.</p>';
34
echo '</div>';
35
}
36
$path = wpstg_get_upload_dir() . '/clone_details.json';
25
26
if ( wpstg_is_admin_page() && !wp_is_writable( wpstg_get_upload_dir() ) ){
27
echo '<div class="error">';
28
+ echo '<p><strong>WP Staging Folder Permission error: </strong>' . wpstg_get_upload_dir() . ' is not write and/or readable. <br> Check if the folder <strong>'.wpstg_get_upload_dir().'</strong> exists! File permissions should be chmod 755 or 777.</p>';
29
echo '</div>';
30
}
31
if ( wpstg_is_admin_page() && !wp_is_writable( WPSTG_PLUGIN_DIR . 'logs' ) ){
32
echo '<div class="error">';
33
+ echo '<p><strong>WP Staging Folder Permission error: </strong>' . WPSTG_PLUGIN_DIR . 'logs' . ' is not write and/or readable. <br> Check if the folder <strong>'.WPSTG_PLUGIN_DIR . 'logs'.'</strong> exists! File permissions should be chmod 755 or 777.</p>';
34
echo '</div>';
35
}
36
$path = wpstg_get_upload_dir() . '/clone_details.json';
includes/admin/upload-functions.php CHANGED
@@ -44,9 +44,20 @@ function wpstg_htaccess_exists() {
44
* @return bool
45
*/
46
function wpstg_remainingjson_exists() {
47
- $upload_path = wpstg_get_upload_dir();
48
-
49
- return file_exists( $upload_path . '/remaining_files.json' );
50
}
51
52
/**
@@ -57,8 +68,18 @@ function wpstg_remainingjson_exists() {
57
*/
58
function wpstg_clonedetailsjson_exists() {
59
$upload_path = wpstg_get_upload_dir();
60
-
61
- return file_exists( $upload_path . '/clone_details.json' );
62
}
63
64
/**
44
* @return bool
45
*/
46
function wpstg_remainingjson_exists() {
47
+ global $wp_filesystem;
48
+ $upload_path = wpstg_get_upload_dir();
49
+ //return file_exists( $upload_path . '/remaining_files.json' );
50
+
51
+ if ( is_readable( $upload_path . '/remaining_files.json' )){
52
+ return true;
53
+ }
54
+
55
+ $writefile = fopen($upload_path . '/remaining_files.json', 'w');
56
+
57
+ if( $writefile ) {
58
+ fclose($writefile);
59
+ return true;
60
+ }
61
}
62
63
/**
68
*/
69
function wpstg_clonedetailsjson_exists() {
70
$upload_path = wpstg_get_upload_dir();
71
+ //return file_exists( $upload_path . '/clone_details.json' );
72
+
73
+ if ( is_readable( $upload_path . '/clone_details.json' )){
74
+ return true;
75
+ }
76
+
77
+ $writefile = fopen($upload_path . '/clone_details.json', 'w');
78
+
79
+ if( $writefile ) {
80
+ fclose($writefile);
81
+ return true;
82
+ }
83
}
84
85
/**
readme.txt CHANGED
@@ -1,4 +1,4 @@
1
- === WP Staging - DB & file duplicator & migration ===
2
3
Author URL: https://wordpress.org/plugins/wp-staging
4
Plugin URL: https://wordpress.org/plugins/wp-staging
@@ -9,7 +9,7 @@ License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
Tags: staging, duplication, cloning, clone, migration, sandbox, test site, testing, backup, post, admin, administration, duplicate posts
10
Requires at least: 3.6+
11
Tested up to: 4.5
12
- Stable tag: 1.0.5
13
14
A duplicator plugin! Clone, duplicate and migrate live sites to independent staging and development sites that are available only to administrators.
15
@@ -141,8 +141,10 @@ After installation goto the settings page 'Staging' and do your adjustments ther
141
142
== Changelog ==
143
144
- = 1.0.5 =
145
* Fix: Uninstalling plugin throwing error
146
147
= 1.0.5 =
148
* New: Tested up to WP 4.5
1
+ === WP Staging - DB & File Duplicator & Migration ===
2
3
Author URL: https://wordpress.org/plugins/wp-staging
4
Plugin URL: https://wordpress.org/plugins/wp-staging
9
Tags: staging, duplication, cloning, clone, migration, sandbox, test site, testing, backup, post, admin, administration, duplicate posts
10
Requires at least: 3.6+
11
Tested up to: 4.5
12
+ Stable tag: 1.0.6
13
14
A duplicator plugin! Clone, duplicate and migrate live sites to independent staging and development sites that are available only to administrators.
15
141
142
== Changelog ==
143
144
+ = 1.0.6 =
145
* Fix: Uninstalling plugin throwing error
146
+ * Fix: Error permission admin notice although permission issues are correct
147
+
148
149
= 1.0.5 =
150
* New: Tested up to WP 4.5
wp-staging.php CHANGED
@@ -6,7 +6,7 @@
6
* Description: Create a staging clone site for testing & developing
7
* Author: WP-Staging, René Hermenau
8
* Author URI: https://wordpress.org/plugins/wp-staging
9
- * Version: 1.0.5
10
* Text Domain: wpstg
11
* Domain Path: languages
12
@@ -34,7 +34,7 @@ if ( !defined('ABSPATH') )
34
35
// Plugin version
36
if ( !defined('WPSTG_VERSION') ) {
37
- define('WPSTG_VERSION', '1.0.5');
38
}
39
// Is compatible up to WordPress version
40
if ( !defined('WPSTG_WP_COMPATIBLE') ) {
6
* Description: Create a staging clone site for testing & developing
7
* Author: WP-Staging, René Hermenau
8
* Author URI: https://wordpress.org/plugins/wp-staging
9
+ * Version: 1.0.6
10
* Text Domain: wpstg
11
* Domain Path: languages
12
34
35
// Plugin version
36
if ( !defined('WPSTG_VERSION') ) {
37
+ define('WPSTG_VERSION', '1.0.6');
38
}
39
// Is compatible up to WordPress version
40
if ( !defined('WPSTG_WP_COMPATIBLE') ) {