Export Users to CSV - Version 1.1.1

Version Description

(March 4, 2018) = * Fixed bug that prevented the date range from working as intended. Thanks @sbskamey for reporting the issue.

Download this release

Release Info

Developer webdevmattcrom
Plugin Icon 128x128 Export Users to CSV
Version 1.1.1
Comparing to
See all releases

Code changes from version 1.1 to 1.1.1

Files changed (2) hide show
  1. export-users-to-csv.php +5 -5
  2. readme.txt +18 -3
export-users-to-csv.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Export Users to CSV
4
  Plugin URI: http://wordpress.org/extend/plugins/export-users-to-csv/
5
  Description: Export Users data and metadata to a csv file.
6
- Version: 1.1
7
  Author: Matt Cromwell
8
  Author URI: https://www.mattcromwell.com/products/export-users-to-csv
9
  License: GPL2
@@ -259,11 +259,11 @@ class PP_EU_Export_Users {
259
 
260
  $where = '';
261
 
262
- if ( ! empty( $_POST['start_date'] ) )
263
- $where .= $wpdb->prepare( " AND $wpdb->users.user_registered >= %s", date( 'Y-m-d', strtotime( $_POST['start_date'] ) ) );
264
 
265
- if ( ! empty( $_POST['end_date'] ) )
266
- $where .= $wpdb->prepare( " AND $wpdb->users.user_registered < %s", date( 'Y-m-d', strtotime( '+1 month', strtotime( $_POST['end_date'] ) ) ) );
267
 
268
  if ( ! empty( $where ) )
269
  $user_search->query_where = str_replace( 'WHERE 1=1', "WHERE 1=1$where", $user_search->query_where );
3
  Plugin Name: Export Users to CSV
4
  Plugin URI: http://wordpress.org/extend/plugins/export-users-to-csv/
5
  Description: Export Users data and metadata to a csv file.
6
+ Version: 1.1.1
7
  Author: Matt Cromwell
8
  Author URI: https://www.mattcromwell.com/products/export-users-to-csv
9
  License: GPL2
259
 
260
  $where = '';
261
 
262
+ if ( ! empty( $_GET['start_date'] ) )
263
+ $where .= $wpdb->prepare( " AND $wpdb->users.user_registered >= %s", date( 'Y-m-d', strtotime( $_GET['start_date'] ) ) );
264
 
265
+ if ( ! empty( $_GET['end_date'] ) )
266
+ $where .= $wpdb->prepare( " AND $wpdb->users.user_registered < %s", date( 'Y-m-d', strtotime( '+1 month', strtotime( $_GET['end_date'] ) ) ) );
267
 
268
  if ( ! empty( $where ) )
269
  $user_search->query_where = str_replace( 'WHERE 1=1', "WHERE 1=1$where", $user_search->query_where );
readme.txt CHANGED
@@ -3,18 +3,20 @@ Contributors: webdevmattcrom
3
  Tags: user, users, csv, batch, export, exporter, admin
4
  Requires at least: 4.2
5
  Tested up to: 4.8
6
- Stable tag: 1.1
7
 
8
- Export users data and metadata to a csv file
9
 
10
  == Description ==
11
 
12
- A plugin that exports ALL user data and user meta to a CSV file, elegantly and simply.
13
 
14
  Export users by role and optionally set a registration date range.
15
 
16
  Export is found in "Tools > Export", or with the "Export Users" button on the Users admin screen.
17
 
 
 
18
  = Features =
19
 
20
  * Exports all users fields
@@ -51,6 +53,16 @@ To upload the plugin through WordPress, instead of FTP:
51
 
52
  Click on the 'Export Users' button at the top of the 'Users' admin screen, or navigate to "Tools > Export." From there, choose "Users" as your export, then choose the role and the date range. Choose nothing at all if you want to export all users, then click 'Export'. That's all!
53
 
 
 
 
 
 
 
 
 
 
 
54
  == Screenshots ==
55
 
56
  1. The User export tool
@@ -58,6 +70,9 @@ Click on the 'Export Users' button at the top of the 'Users' admin screen, or na
58
 
59
  == Changelog ==
60
 
 
 
 
61
  = 1.1 (February 25, 2018) =
62
  * Moved screen to the "Tools > Export" screen to leverage WordPress core export features. [Github Issue #2](https://github.com/mathetos/export-users-to-csv/issues/2)
63
  * Removed local translations and updated load_textdomain to look for the localized files in the correct WordPress core folder. [Github Issue #1](https://github.com/mathetos/export-users-to-csv/issues/1)
3
  Tags: user, users, csv, batch, export, exporter, admin
4
  Requires at least: 4.2
5
  Tested up to: 4.8
6
+ Stable tag: 1.1.1
7
 
8
+ Export users data and metadata to a csv file.
9
 
10
  == Description ==
11
 
12
+ A WordPress plugin that exports user data and meta data. You can even export the users by role and registration date range.
13
 
14
  Export users by role and optionally set a registration date range.
15
 
16
  Export is found in "Tools > Export", or with the "Export Users" button on the Users admin screen.
17
 
18
+ By default, it does not export user passwords as a security concern. See the [FAQ](#faq) for how to include them regardless.
19
+
20
  = Features =
21
 
22
  * Exports all users fields
53
 
54
  Click on the 'Export Users' button at the top of the 'Users' admin screen, or navigate to "Tools > Export." From there, choose "Users" as your export, then choose the role and the date range. Choose nothing at all if you want to export all users, then click 'Export'. That's all!
55
 
56
+ = How do I include the Passwords? =
57
+
58
+ I don't really recommend it since storing passwords in plain-text can be a real liability issue. Nevertheless, you can add this filter to your site to allow the password to be included as a column in your CSV file:
59
+
60
+ `add_filter('pp_eu_exclude_data', 'my_prefix_include_password');
61
+
62
+ function my_prefix_include_password() {
63
+ return array();
64
+ }`
65
+
66
  == Screenshots ==
67
 
68
  1. The User export tool
70
 
71
  == Changelog ==
72
 
73
+ = 1.1.1 (March 4, 2018) =
74
+ * Fixed bug that prevented the date range from working as intended. Thanks @sbskamey for [reporting the issue](https://github.com/mathetos/export-users-to-csv/issues/12).
75
+
76
  = 1.1 (February 25, 2018) =
77
  * Moved screen to the "Tools > Export" screen to leverage WordPress core export features. [Github Issue #2](https://github.com/mathetos/export-users-to-csv/issues/2)
78
  * Removed local translations and updated load_textdomain to look for the localized files in the correct WordPress core folder. [Github Issue #1](https://github.com/mathetos/export-users-to-csv/issues/1)