WordPress Database Reset - Version 3.19

Version Description

  • 2021/02/25
  • continuing to phase out the plugin in favor of WP Reset
Download this release

Release Info

Developer WebFactory
Plugin Icon 128x128 WordPress Database Reset
Version 3.19
Comparing to
See all releases

Code changes from version 3.18 to 3.19

assets/js/database-reset-plugins.js ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ (function ($) {
2
+ var plugin_row = $("tr[data-slug='wordpress-database-reset']");
3
+ if (plugin_row.length == 1) {
4
+ var row = '<tr class="plugin-update-tr active"><td colspan="4" class="plugin-update colspanchange"><div class="update-message notice inline notice-error notice-alt">';
5
+ row += '<p>WP Database Reset has been replaced by <a href="' + db_reset.info_link +'" class="thickbox open-plugin-details-modal">WP Reset</a> and it will soon be removed from the plugin repository.<br>Please <a href="' + db_reset.install_link + '">click here to install WP Reset</a> - it\'s free, used by over 300,000 people and has numerous reset tools. If you have any questions - <a href="https://wordpress.org/support/plugin/wordpress-database-reset/" target="_blank">contact support</a></p>';
6
+ row += '</div></td></tr>';
7
+
8
+ $(row).insertAfter($(plugin_row));
9
+ $(plugin_row).addClass('update');
10
+ }
11
+ })(jQuery);
class-db-reset-admin.php CHANGED
@@ -64,8 +64,24 @@ if (!class_exists('DB_Reset_Admin')) :
64
  add_filter('plugin_action_links_' . plugin_basename(DB_RESET_FILE), array($this, 'plugin_action_links'));
65
  add_filter('plugin_row_meta', array($this, 'plugin_meta_links'), 10, 2);
66
  add_filter('admin_footer_text', array($this, 'admin_footer_text'));
 
67
  }
68
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
69
 
70
  // additional powered by text in admin footer; only on plugin's page
71
  static function admin_footer_text($text)
64
  add_filter('plugin_action_links_' . plugin_basename(DB_RESET_FILE), array($this, 'plugin_action_links'));
65
  add_filter('plugin_row_meta', array($this, 'plugin_meta_links'), 10, 2);
66
  add_filter('admin_footer_text', array($this, 'admin_footer_text'));
67
+ add_action('admin_enqueue_scripts', array($this, 'admin_enqueue_scripts'));
68
  }
69
 
70
+ public function admin_enqueue_scripts() {
71
+ $current_screen = get_current_screen();
72
+ if ($current_screen->id != 'plugins') {
73
+ return;
74
+ }
75
+
76
+ wp_enqueue_script('db-reset', plugins_url('assets/js/database-reset-plugins.js', __FILE__), array('jquery'), $this->version, true);
77
+
78
+ $vars = array();
79
+ $vars['info_link'] = admin_url('plugin-install.php?tab=plugin-information&plugin=wp-reset&TB_iframe=true&width=600&height=800');
80
+ $vars['install_link'] = wp_nonce_url(add_query_arg(array('action' => 'install-plugin', 'plugin' => 'wp-reset'), admin_url('update.php')), 'install-plugin_wp-reset');
81
+
82
+ wp_localize_script('db-reset', 'db_reset', $vars);
83
+ } // admin_enqueue
84
+
85
 
86
  // additional powered by text in admin footer; only on plugin's page
87
  static function admin_footer_text($text)
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: WebFactory
3
  Tags: database, reset, restore, database reset, wp reset, reset wp, developer, development
4
  Requires at least: 4.2
5
  Requires PHP: 5.2
6
- Tested up to: 5.6
7
- Stable tag: 3.18
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -65,6 +65,10 @@ WP Database Reset was originally developed in October 2011 by <a href="https://g
65
 
66
  == Changelog ==
67
 
 
 
 
 
68
  = 3.18 =
69
  * 2021/01/30
70
  * added flyout menu
3
  Tags: database, reset, restore, database reset, wp reset, reset wp, developer, development
4
  Requires at least: 4.2
5
  Requires PHP: 5.2
6
+ Tested up to: 5.7
7
+ Stable tag: 3.19
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
65
 
66
  == Changelog ==
67
 
68
+ = 3.19 =
69
+ * 2021/02/25
70
+ * continuing to phase out the plugin in favor of WP Reset
71
+
72
  = 3.18 =
73
  * 2021/01/30
74
  * added flyout menu
wp-reset.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: WP Database Reset
4
  Plugin URI: https://wordpress.org/plugins/wordpress-database-reset/
5
  Description: Reset all or some WP database tables back to their original state.
6
- Version: 3.18
7
  Author: WebFactory Ltd
8
  Author URI: https://www.webfactoryltd.com/
9
  License: GNU General Public License
3
  Plugin Name: WP Database Reset
4
  Plugin URI: https://wordpress.org/plugins/wordpress-database-reset/
5
  Description: Reset all or some WP database tables back to their original state.
6
+ Version: 3.19
7
  Author: WebFactory Ltd
8
  Author URI: https://www.webfactoryltd.com/
9
  License: GNU General Public License