WordPress Reset - Version 1.3.1

Version Description

Fixes a deprecated notice in WordPress 3.3, removed the $auto_reactivate variable, and look for REACTIVATE_WP_RESET to be defined in wp-config.php, as well as the ability to activate additional plugins using a global $reactivate_wp_reset_additional array defined in wp-config.php

=

Download this release

Release Info

Developer sivel
Plugin Icon WordPress Reset
Version 1.3.1
Comparing to
See all releases

Code changes from version 1.3 to 1.3.1

Files changed (2) hide show
  1. readme.txt +5 -2
  2. wordpress-reset.php +4 -2
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate Link: http://sivel.net/donate
4
  Tags: wordpress-reset, wordpress, reset, admin
5
  Requires at least: 2.8
6
  Tested up to: 3.3
7
- Stable tag: 1.3
8
 
9
  Resets the WordPress database back to it's defaults. Deletes all customizations and content. Does not modify files only resets the database.
10
 
@@ -53,12 +53,15 @@ $reactivate_wp_reset_additional = array(
53
 
54
  == Upgrade Notice ==
55
 
56
- = 1.3 =
57
 
58
  Fixes a deprecated notice in WordPress 3.3, removed the $auto_reactivate variable, and look for REACTIVATE_WP_RESET to be defined in wp-config.php, as well as the ability to activate additional plugins using a global $reactivate_wp_reset_additional array defined in wp-config.php
59
 
60
  == Changelog ==
61
 
 
 
 
62
  = 1.3 (2012-01-29): =
63
  * Fixes a deprecated notice in WordPress 3.3 when using get_userdatabylogin
64
  * Removes the $auto_reactivate variable
4
  Tags: wordpress-reset, wordpress, reset, admin
5
  Requires at least: 2.8
6
  Tested up to: 3.3
7
+ Stable tag: 1.3.1
8
 
9
  Resets the WordPress database back to it's defaults. Deletes all customizations and content. Does not modify files only resets the database.
10
 
53
 
54
  == Upgrade Notice ==
55
 
56
+ = 1.3.1 =
57
 
58
  Fixes a deprecated notice in WordPress 3.3, removed the $auto_reactivate variable, and look for REACTIVATE_WP_RESET to be defined in wp-config.php, as well as the ability to activate additional plugins using a global $reactivate_wp_reset_additional array defined in wp-config.php
59
 
60
  == Changelog ==
61
 
62
+ = 1.3.1 (2012-01-29): =
63
+ * Apparently in a LIKE query, an underscore matches a single character, so we must escape it
64
+
65
  = 1.3 (2012-01-29): =
66
  * Fixes a deprecated notice in WordPress 3.3 when using get_userdatabylogin
67
  * Removes the $auto_reactivate variable
wordpress-reset.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: WordPress Reset
4
  Plugin URI: http://sivel.net/wordpress/wordpress-reset/
5
  Description: Resets the WordPress database back to it's defaults. Deletes all customizations and content. Does not modify files only resets the database.
6
  Author: Matt Martz
7
- Version: 1.3
8
  Author URI: http://sivel.net/
9
 
10
  Copyright (c) 2009-2012 Matt Martz (http://sivel.net)
@@ -70,7 +70,9 @@ class WordPressReset {
70
  $user = $current_user;
71
 
72
  global $wpdb, $reactivate_wp_reset_additional;
73
- $tables = $wpdb->get_col( "SHOW TABLES LIKE '{$wpdb->prefix}%'" );
 
 
74
  foreach ( $tables as $table ) {
75
  $wpdb->query( "DROP TABLE $table" );
76
  }
4
  Plugin URI: http://sivel.net/wordpress/wordpress-reset/
5
  Description: Resets the WordPress database back to it's defaults. Deletes all customizations and content. Does not modify files only resets the database.
6
  Author: Matt Martz
7
+ Version: 1.3.1
8
  Author URI: http://sivel.net/
9
 
10
  Copyright (c) 2009-2012 Matt Martz (http://sivel.net)
70
  $user = $current_user;
71
 
72
  global $wpdb, $reactivate_wp_reset_additional;
73
+
74
+ $prefix = str_replace( '_', '\_', $wpdb->prefix );
75
+ $tables = $wpdb->get_col( "SHOW TABLES LIKE '{$prefix}%'" );
76
  foreach ( $tables as $table ) {
77
  $wpdb->query( "DROP TABLE $table" );
78
  }