@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | */ |
11 | 11 | |
12 | 12 | // Exit if accessed directly. |
13 | -if ( ! defined( 'ABSPATH' ) ) { |
|
13 | +if ( ! defined('ABSPATH')) { |
|
14 | 14 | exit; |
15 | 15 | } |
16 | 16 | |
@@ -27,30 +27,30 @@ discard block |
||
27 | 27 | * |
28 | 28 | * @return mixed |
29 | 29 | */ |
30 | -function __give_sanitize_number_decimals_setting_field( $value ) { |
|
30 | +function __give_sanitize_number_decimals_setting_field($value) { |
|
31 | 31 | $value_changed = false; |
32 | 32 | $old_value = $value; |
33 | 33 | |
34 | - if ( isset( $_POST['decimal_separator'] ) ) { |
|
35 | - $value = ! empty( $_POST['decimal_separator'] ) ? $value : 0; |
|
34 | + if (isset($_POST['decimal_separator'])) { |
|
35 | + $value = ! empty($_POST['decimal_separator']) ? $value : 0; |
|
36 | 36 | $value_changed = true; |
37 | 37 | } |
38 | 38 | |
39 | - if ( $value_changed && ( $old_value != $value ) ) { |
|
40 | - Give_Admin_Settings::add_error( 'give-number-decimal', __( 'The \'Number of Decimals\' option has been automatically set to zero because the \'Decimal Separator\' is not set.', 'give' ) ); |
|
39 | + if ($value_changed && ($old_value != $value)) { |
|
40 | + Give_Admin_Settings::add_error('give-number-decimal', __('The \'Number of Decimals\' option has been automatically set to zero because the \'Decimal Separator\' is not set.', 'give')); |
|
41 | 41 | } |
42 | 42 | |
43 | - $value = absint( $value ); |
|
43 | + $value = absint($value); |
|
44 | 44 | |
45 | - if( 6 <= $value ) { |
|
45 | + if (6 <= $value) { |
|
46 | 46 | $value = 5; |
47 | - Give_Admin_Settings::add_error( 'give-number-decimal', __( 'The \'Number of Decimals\' option has been automatically set to 5 because you entered a number higher than the maximum allowed.', 'give' ) ); |
|
47 | + Give_Admin_Settings::add_error('give-number-decimal', __('The \'Number of Decimals\' option has been automatically set to 5 because you entered a number higher than the maximum allowed.', 'give')); |
|
48 | 48 | } |
49 | 49 | |
50 | - return absint( $value ); |
|
50 | + return absint($value); |
|
51 | 51 | } |
52 | 52 | |
53 | -add_filter( 'give_admin_settings_sanitize_option_number_decimals', '__give_sanitize_number_decimals_setting_field', 10 ); |
|
53 | +add_filter('give_admin_settings_sanitize_option_number_decimals', '__give_sanitize_number_decimals_setting_field', 10); |
|
54 | 54 | |
55 | 55 | |
56 | 56 | /** |
@@ -66,20 +66,20 @@ discard block |
||
66 | 66 | * |
67 | 67 | * @return mixed |
68 | 68 | */ |
69 | -function __give_validate_decimal_separator_setting_field( $value ) { |
|
70 | - $thousand_separator = give_clean( $_POST['thousands_separator'] ); |
|
71 | - $decimal_separator = give_clean( $_POST['decimal_separator'] ); |
|
69 | +function __give_validate_decimal_separator_setting_field($value) { |
|
70 | + $thousand_separator = give_clean($_POST['thousands_separator']); |
|
71 | + $decimal_separator = give_clean($_POST['decimal_separator']); |
|
72 | 72 | |
73 | - if ( $decimal_separator === $thousand_separator ) { |
|
73 | + if ($decimal_separator === $thousand_separator) { |
|
74 | 74 | $value = ''; |
75 | 75 | $_POST['number_decimals'] = 0; |
76 | - Give_Admin_Settings::add_error( 'give-decimal-separator', __( 'The \'Decimal Separator\' option has automatically been set to empty because it can not be equal to the \'Thousand Separator\'', 'give' ) ); |
|
76 | + Give_Admin_Settings::add_error('give-decimal-separator', __('The \'Decimal Separator\' option has automatically been set to empty because it can not be equal to the \'Thousand Separator\'', 'give')); |
|
77 | 77 | } |
78 | 78 | |
79 | 79 | return $value; |
80 | 80 | } |
81 | 81 | |
82 | -add_filter( 'give_admin_settings_sanitize_option_decimal_separator', '__give_validate_decimal_separator_setting_field', 10 ); |
|
82 | +add_filter('give_admin_settings_sanitize_option_decimal_separator', '__give_validate_decimal_separator_setting_field', 10); |
|
83 | 83 | |
84 | 84 | /** |
85 | 85 | * Change $delimiter text to symbol. |
@@ -90,16 +90,16 @@ discard block |
||
90 | 90 | * |
91 | 91 | * @return string $delimiter. |
92 | 92 | */ |
93 | -function __give_import_delimiter_set_callback( $delimiter ) { |
|
93 | +function __give_import_delimiter_set_callback($delimiter) { |
|
94 | 94 | $delimite_type = array( |
95 | 95 | 'csv' => ",", |
96 | 96 | 'tab-separated-values' => "\t", |
97 | 97 | ); |
98 | 98 | |
99 | - return ( array_key_exists( $delimiter, $delimite_type ) ? $delimite_type[ $delimiter ] : "," ); |
|
99 | + return (array_key_exists($delimiter, $delimite_type) ? $delimite_type[$delimiter] : ","); |
|
100 | 100 | } |
101 | 101 | |
102 | -add_filter( 'give_import_delimiter_set', '__give_import_delimiter_set_callback', 10 ); |
|
102 | +add_filter('give_import_delimiter_set', '__give_import_delimiter_set_callback', 10); |
|
103 | 103 | |
104 | 104 | /** |
105 | 105 | * Give unset the page id from the core setting data from the json files. |
@@ -111,17 +111,17 @@ discard block |
||
111 | 111 | * |
112 | 112 | * @return array $json_to_array |
113 | 113 | */ |
114 | -function give_import_core_settings_merge_pages( $json_to_array, $type ) { |
|
115 | - if ( 'merge' === $type ) { |
|
116 | - unset( $json_to_array['success_page'] ); |
|
117 | - unset( $json_to_array['failure_page'] ); |
|
118 | - unset( $json_to_array['history_page'] ); |
|
114 | +function give_import_core_settings_merge_pages($json_to_array, $type) { |
|
115 | + if ('merge' === $type) { |
|
116 | + unset($json_to_array['success_page']); |
|
117 | + unset($json_to_array['failure_page']); |
|
118 | + unset($json_to_array['history_page']); |
|
119 | 119 | } |
120 | 120 | |
121 | 121 | return $json_to_array; |
122 | 122 | } |
123 | 123 | |
124 | -add_filter( 'give_import_core_settings_data', 'give_import_core_settings_merge_pages', 11, 2 ); |
|
124 | +add_filter('give_import_core_settings_data', 'give_import_core_settings_merge_pages', 11, 2); |
|
125 | 125 | |
126 | 126 | /** |
127 | 127 | * Give check the image size from the core setting data from the json files. |
@@ -133,14 +133,14 @@ discard block |
||
133 | 133 | * |
134 | 134 | * @return array $json_to_array |
135 | 135 | */ |
136 | -function give_import_core_settings_merge_image_size( $json_to_array, $type ) { |
|
137 | - if ( 'merge' === $type ) { |
|
136 | +function give_import_core_settings_merge_image_size($json_to_array, $type) { |
|
137 | + if ('merge' === $type) { |
|
138 | 138 | // Featured image sizes import under Display Options > Post Types > Featured Image Size. |
139 | - if ( 'enabled' === $json_to_array['form_featured_img'] ) { |
|
139 | + if ('enabled' === $json_to_array['form_featured_img']) { |
|
140 | 140 | $images_sizes = get_intermediate_image_sizes(); |
141 | 141 | |
142 | - if ( ! in_array( $json_to_array['featured_image_size'], $images_sizes ) ) { |
|
143 | - unset( $json_to_array['featured_image_size'] ); |
|
142 | + if ( ! in_array($json_to_array['featured_image_size'], $images_sizes)) { |
|
143 | + unset($json_to_array['featured_image_size']); |
|
144 | 144 | } |
145 | 145 | } |
146 | 146 | } |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | return $json_to_array; |
149 | 149 | } |
150 | 150 | |
151 | -add_filter( 'give_import_core_settings_data', 'give_import_core_settings_merge_image_size', 12, 2 ); |
|
151 | +add_filter('give_import_core_settings_data', 'give_import_core_settings_merge_image_size', 12, 2); |
|
152 | 152 | |
153 | 153 | /** |
154 | 154 | * Give upload the image logo from the core setting data from the json files. |
@@ -160,24 +160,24 @@ discard block |
||
160 | 160 | * |
161 | 161 | * @return array $json_to_array |
162 | 162 | */ |
163 | -function give_import_core_settings_merge_upload_image( $json_to_array, $type ) { |
|
164 | - if ( 'merge' === $type ) { |
|
163 | +function give_import_core_settings_merge_upload_image($json_to_array, $type) { |
|
164 | + if ('merge' === $type) { |
|
165 | 165 | // Emails > Email Settings > Logo. |
166 | - if ( ! empty( $json_to_array['email_logo'] ) ) { |
|
166 | + if ( ! empty($json_to_array['email_logo'])) { |
|
167 | 167 | |
168 | 168 | // Need to require these files. |
169 | - if ( ! function_exists( 'media_handle_upload' ) ) { |
|
170 | - require_once( ABSPATH . 'wp-admin/includes/image.php' ); |
|
171 | - require_once( ABSPATH . 'wp-admin/includes/file.php' ); |
|
172 | - require_once( ABSPATH . 'wp-admin/includes/media.php' ); |
|
169 | + if ( ! function_exists('media_handle_upload')) { |
|
170 | + require_once(ABSPATH.'wp-admin/includes/image.php'); |
|
171 | + require_once(ABSPATH.'wp-admin/includes/file.php'); |
|
172 | + require_once(ABSPATH.'wp-admin/includes/media.php'); |
|
173 | 173 | } |
174 | 174 | |
175 | 175 | $url = $json_to_array['email_logo']; |
176 | - $new_url = media_sideload_image( $url, 0, null, 'src' ); |
|
177 | - if ( ! is_wp_error( $new_url ) ) { |
|
176 | + $new_url = media_sideload_image($url, 0, null, 'src'); |
|
177 | + if ( ! is_wp_error($new_url)) { |
|
178 | 178 | $json_to_array['email_logo'] = $new_url; |
179 | 179 | } else { |
180 | - unset( $json_to_array['email_logo'] ); |
|
180 | + unset($json_to_array['email_logo']); |
|
181 | 181 | } |
182 | 182 | } |
183 | 183 | } |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | return $json_to_array; |
186 | 186 | } |
187 | 187 | |
188 | -add_filter( 'give_import_core_settings_data', 'give_import_core_settings_merge_upload_image', 13, 2 ); |
|
188 | +add_filter('give_import_core_settings_data', 'give_import_core_settings_merge_upload_image', 13, 2); |
|
189 | 189 | |
190 | 190 | /** |
191 | 191 | * Give unset the license key from the core setting data from the json files. |
@@ -197,12 +197,12 @@ discard block |
||
197 | 197 | * |
198 | 198 | * @return array $json_to_array |
199 | 199 | */ |
200 | -function give_import_core_settings_merge_license_key( $json_to_array, $type ) { |
|
201 | - if ( 'merge' === $type ) { |
|
202 | - foreach ( $json_to_array as $key => $value ) { |
|
203 | - $is_license_key = strpos( '_license_key', $key ); |
|
204 | - if ( ! empty( $is_license_key ) ) { |
|
205 | - unset( $json_to_array[ $key ] ); |
|
200 | +function give_import_core_settings_merge_license_key($json_to_array, $type) { |
|
201 | + if ('merge' === $type) { |
|
202 | + foreach ($json_to_array as $key => $value) { |
|
203 | + $is_license_key = strpos('_license_key', $key); |
|
204 | + if ( ! empty($is_license_key)) { |
|
205 | + unset($json_to_array[$key]); |
|
206 | 206 | } |
207 | 207 | } |
208 | 208 | } |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | return $json_to_array; |
211 | 211 | } |
212 | 212 | |
213 | -add_filter( 'give_import_core_settings_data', 'give_import_core_settings_merge_license_key', 14, 2 ); |
|
213 | +add_filter('give_import_core_settings_data', 'give_import_core_settings_merge_license_key', 14, 2); |
|
214 | 214 | |
215 | 215 | /** |
216 | 216 | * Give merge the json data and setting data. |
@@ -223,16 +223,16 @@ discard block |
||
223 | 223 | * |
224 | 224 | * @return array $json_to_array |
225 | 225 | */ |
226 | -function give_import_core_settings_merge_data( $json_to_array, $type, $host_give_options ) { |
|
227 | - if ( 'merge' === $type ) { |
|
228 | - $json_to_array_merge = array_merge( $host_give_options, $json_to_array ); |
|
226 | +function give_import_core_settings_merge_data($json_to_array, $type, $host_give_options) { |
|
227 | + if ('merge' === $type) { |
|
228 | + $json_to_array_merge = array_merge($host_give_options, $json_to_array); |
|
229 | 229 | $json_to_array = $json_to_array_merge; |
230 | 230 | } |
231 | 231 | |
232 | 232 | return $json_to_array; |
233 | 233 | } |
234 | 234 | |
235 | -add_filter( 'give_import_core_settings_data', 'give_import_core_settings_merge_data', 1000, 3 ); |
|
235 | +add_filter('give_import_core_settings_data', 'give_import_core_settings_merge_data', 1000, 3); |
|
236 | 236 | |
237 | 237 | /** |
238 | 238 | * Backward Compatibility - Cleanup User Roles. |
@@ -243,11 +243,11 @@ discard block |
||
243 | 243 | * |
244 | 244 | * @return mixed |
245 | 245 | */ |
246 | -function give_bc_1817_cleanup_user_roles( $caps ){ |
|
246 | +function give_bc_1817_cleanup_user_roles($caps) { |
|
247 | 247 | |
248 | 248 | if ( |
249 | - ! give_has_upgrade_completed( 'v1817_cleanup_user_roles' ) && |
|
250 | - ! isset( $caps['view_give_payments'] ) |
|
249 | + ! give_has_upgrade_completed('v1817_cleanup_user_roles') && |
|
250 | + ! isset($caps['view_give_payments']) |
|
251 | 251 | ) { |
252 | 252 | give_v1817_process_cleanup_user_roles(); |
253 | 253 | } |
@@ -255,4 +255,4 @@ discard block |
||
255 | 255 | return $caps; |
256 | 256 | } |
257 | 257 | |
258 | -add_filter( 'user_has_cap', 'give_bc_1817_cleanup_user_roles' ); |
|
259 | 258 | \ No newline at end of file |
259 | +add_filter('user_has_cap', 'give_bc_1817_cleanup_user_roles'); |
|
260 | 260 | \ No newline at end of file |
@@ -9,11 +9,11 @@ discard block |
||
9 | 9 | * @since 1.8 |
10 | 10 | */ |
11 | 11 | |
12 | -if ( ! defined( 'ABSPATH' ) ) { |
|
12 | +if ( ! defined('ABSPATH')) { |
|
13 | 13 | exit; // Exit if accessed directly |
14 | 14 | } |
15 | 15 | |
16 | -if ( ! class_exists( 'Give_Settings_Export' ) ) : |
|
16 | +if ( ! class_exists('Give_Settings_Export')) : |
|
17 | 17 | |
18 | 18 | /** |
19 | 19 | * Give_Settings_Export. |
@@ -34,16 +34,16 @@ discard block |
||
34 | 34 | */ |
35 | 35 | public function __construct() { |
36 | 36 | $this->id = 'export'; |
37 | - $this->label = __( 'Export', 'give' ); |
|
37 | + $this->label = __('Export', 'give'); |
|
38 | 38 | |
39 | 39 | parent::__construct(); |
40 | 40 | |
41 | - add_action( 'give_admin_field_tools_export', array( $this, 'render_export_field' ), 10, 2 ); |
|
41 | + add_action('give_admin_field_tools_export', array($this, 'render_export_field'), 10, 2); |
|
42 | 42 | |
43 | 43 | // Do not use main donor for this tab. |
44 | - if( give_get_current_setting_tab() === $this->id ) { |
|
45 | - add_action( 'give-tools_open_form', '__return_empty_string' ); |
|
46 | - add_action( 'give-tools_close_form', '__return_empty_string' ); |
|
44 | + if (give_get_current_setting_tab() === $this->id) { |
|
45 | + add_action('give-tools_open_form', '__return_empty_string'); |
|
46 | + add_action('give-tools_close_form', '__return_empty_string'); |
|
47 | 47 | } |
48 | 48 | } |
49 | 49 | |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | * @param array $settings |
62 | 62 | */ |
63 | 63 | $settings = apply_filters( |
64 | - 'give_get_settings_' . $this->id, |
|
64 | + 'give_get_settings_'.$this->id, |
|
65 | 65 | array( |
66 | 66 | array( |
67 | 67 | 'id' => 'give_tools_export', |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | ), |
71 | 71 | array( |
72 | 72 | 'id' => 'export', |
73 | - 'name' => __( 'Export', 'give' ), |
|
73 | + 'name' => __('Export', 'give'), |
|
74 | 74 | 'type' => 'tools_export', |
75 | 75 | ), |
76 | 76 | array( |
@@ -94,8 +94,8 @@ discard block |
||
94 | 94 | * @param $field |
95 | 95 | * @param $option_value |
96 | 96 | */ |
97 | - public function render_export_field( $field, $option_value ) { |
|
98 | - include_once( 'views/html-admin-page-exports.php' ); |
|
97 | + public function render_export_field($field, $option_value) { |
|
98 | + include_once('views/html-admin-page-exports.php'); |
|
99 | 99 | } |
100 | 100 | } |
101 | 101 |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | * @license https://opensource.org/licenses/gpl-license GNU Public License |
11 | 11 | */ |
12 | 12 | |
13 | -if ( ! defined( 'ABSPATH' ) ) { |
|
13 | +if ( ! defined('ABSPATH')) { |
|
14 | 14 | exit; |
15 | 15 | } |
16 | 16 | |
@@ -22,13 +22,13 @@ discard block |
||
22 | 22 | */ |
23 | 23 | function give_process_batch_export_form() { |
24 | 24 | |
25 | - if ( ! wp_verify_nonce( $_REQUEST['nonce'], 'give-batch-export' ) ) { |
|
26 | - wp_die( esc_html__( 'Nonce verification failed.', 'give' ), esc_html__( 'Error', 'give' ), array( |
|
25 | + if ( ! wp_verify_nonce($_REQUEST['nonce'], 'give-batch-export')) { |
|
26 | + wp_die(esc_html__('Nonce verification failed.', 'give'), esc_html__('Error', 'give'), array( |
|
27 | 27 | 'response' => 403, |
28 | - ) ); |
|
28 | + )); |
|
29 | 29 | } |
30 | 30 | |
31 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-batch-export.php'; |
|
31 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-batch-export.php'; |
|
32 | 32 | |
33 | 33 | /** |
34 | 34 | * Fires before batch export. |
@@ -37,14 +37,14 @@ discard block |
||
37 | 37 | * |
38 | 38 | * @param string $class Export class. |
39 | 39 | */ |
40 | - do_action( 'give_batch_export_class_include', $_REQUEST['class'] ); |
|
40 | + do_action('give_batch_export_class_include', $_REQUEST['class']); |
|
41 | 41 | |
42 | 42 | $export = new $_REQUEST['class']; |
43 | 43 | $export->export(); |
44 | 44 | |
45 | 45 | } |
46 | 46 | |
47 | -add_action( 'give_form_batch_export', 'give_process_batch_export_form' ); |
|
47 | +add_action('give_form_batch_export', 'give_process_batch_export_form'); |
|
48 | 48 | |
49 | 49 | /** |
50 | 50 | * Exports earnings for a specified time period. |
@@ -55,14 +55,14 @@ discard block |
||
55 | 55 | * @return void |
56 | 56 | */ |
57 | 57 | function give_export_earnings() { |
58 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-export-earnings.php'; |
|
58 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-export-earnings.php'; |
|
59 | 59 | |
60 | 60 | $earnings_export = new Give_Earnings_Export(); |
61 | 61 | |
62 | 62 | $earnings_export->export(); |
63 | 63 | } |
64 | 64 | |
65 | -add_action( 'give_earnings_export', 'give_export_earnings' ); |
|
65 | +add_action('give_earnings_export', 'give_export_earnings'); |
|
66 | 66 | |
67 | 67 | /** |
68 | 68 | * Exports Give's core settings. |
@@ -73,14 +73,14 @@ discard block |
||
73 | 73 | * @return void |
74 | 74 | */ |
75 | 75 | function give_core_settings_export() { |
76 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-core-settings-export.php'; |
|
76 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-core-settings-export.php'; |
|
77 | 77 | |
78 | 78 | $core_settings = new Give_Core_Settings_Export(); |
79 | 79 | |
80 | 80 | $core_settings->export(); |
81 | 81 | } |
82 | 82 | |
83 | -add_action( 'give_core_settings_export', 'give_core_settings_export' ); |
|
83 | +add_action('give_core_settings_export', 'give_core_settings_export'); |
|
84 | 84 | |
85 | 85 | |
86 | 86 | /** |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | * @return void |
91 | 91 | */ |
92 | 92 | function give_register_batch_exporters() { |
93 | - if ( is_admin() ) { |
|
93 | + if (is_admin()) { |
|
94 | 94 | /** |
95 | 95 | * Fires in the admin, while plugins loaded. |
96 | 96 | * |
@@ -100,11 +100,11 @@ discard block |
||
100 | 100 | * |
101 | 101 | * @param string $class Export class. |
102 | 102 | */ |
103 | - do_action( 'give_register_batch_exporter' ); |
|
103 | + do_action('give_register_batch_exporter'); |
|
104 | 104 | } |
105 | 105 | } |
106 | 106 | |
107 | -add_action( 'plugins_loaded', 'give_register_batch_exporters' ); |
|
107 | +add_action('plugins_loaded', 'give_register_batch_exporters'); |
|
108 | 108 | |
109 | 109 | /** |
110 | 110 | * Register the payments batch exporter |
@@ -112,10 +112,10 @@ discard block |
||
112 | 112 | * @since 1.5 |
113 | 113 | */ |
114 | 114 | function give_register_payments_batch_export() { |
115 | - add_action( 'give_batch_export_class_include', 'give_include_payments_batch_processor', 10, 1 ); |
|
115 | + add_action('give_batch_export_class_include', 'give_include_payments_batch_processor', 10, 1); |
|
116 | 116 | } |
117 | 117 | |
118 | -add_action( 'give_register_batch_exporter', 'give_register_payments_batch_export', 10 ); |
|
118 | +add_action('give_register_batch_exporter', 'give_register_payments_batch_export', 10); |
|
119 | 119 | |
120 | 120 | /** |
121 | 121 | * Loads the payments batch process if needed |
@@ -126,10 +126,10 @@ discard block |
||
126 | 126 | * |
127 | 127 | * @return void |
128 | 128 | */ |
129 | -function give_include_payments_batch_processor( $class ) { |
|
129 | +function give_include_payments_batch_processor($class) { |
|
130 | 130 | |
131 | - if ( 'Give_Batch_Payments_Export' === $class ) { |
|
132 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-batch-export-payments.php'; |
|
131 | + if ('Give_Batch_Payments_Export' === $class) { |
|
132 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-batch-export-payments.php'; |
|
133 | 133 | } |
134 | 134 | |
135 | 135 | } |
@@ -140,10 +140,10 @@ discard block |
||
140 | 140 | * @since 1.5.2 |
141 | 141 | */ |
142 | 142 | function give_register_donors_batch_export() { |
143 | - add_action( 'give_batch_export_class_include', 'give_include_donors_batch_processor', 10, 1 ); |
|
143 | + add_action('give_batch_export_class_include', 'give_include_donors_batch_processor', 10, 1); |
|
144 | 144 | } |
145 | 145 | |
146 | -add_action( 'give_register_batch_exporter', 'give_register_donors_batch_export', 10 ); |
|
146 | +add_action('give_register_batch_exporter', 'give_register_donors_batch_export', 10); |
|
147 | 147 | |
148 | 148 | /** |
149 | 149 | * Loads the donors batch process if needed. |
@@ -154,10 +154,10 @@ discard block |
||
154 | 154 | * |
155 | 155 | * @return void |
156 | 156 | */ |
157 | -function give_include_donors_batch_processor( $class ) { |
|
157 | +function give_include_donors_batch_processor($class) { |
|
158 | 158 | |
159 | - if ( 'Give_Batch_Donors_Export' === $class ) { |
|
160 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-batch-export-donors.php'; |
|
159 | + if ('Give_Batch_Donors_Export' === $class) { |
|
160 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-batch-export-donors.php'; |
|
161 | 161 | } |
162 | 162 | |
163 | 163 | } |
@@ -168,10 +168,10 @@ discard block |
||
168 | 168 | * @since 1.5 |
169 | 169 | */ |
170 | 170 | function give_register_forms_batch_export() { |
171 | - add_action( 'give_batch_export_class_include', 'give_include_forms_batch_processor', 10, 1 ); |
|
171 | + add_action('give_batch_export_class_include', 'give_include_forms_batch_processor', 10, 1); |
|
172 | 172 | } |
173 | 173 | |
174 | -add_action( 'give_register_batch_exporter', 'give_register_forms_batch_export', 10 ); |
|
174 | +add_action('give_register_batch_exporter', 'give_register_forms_batch_export', 10); |
|
175 | 175 | |
176 | 176 | /** |
177 | 177 | * Loads the file downloads batch process if needed |
@@ -182,10 +182,10 @@ discard block |
||
182 | 182 | * |
183 | 183 | * @return void |
184 | 184 | */ |
185 | -function give_include_forms_batch_processor( $class ) { |
|
185 | +function give_include_forms_batch_processor($class) { |
|
186 | 186 | |
187 | - if ( 'Give_Batch_Forms_Export' === $class ) { |
|
188 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/export/class-batch-export-forms.php'; |
|
187 | + if ('Give_Batch_Forms_Export' === $class) { |
|
188 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/export/class-batch-export-forms.php'; |
|
189 | 189 | } |
190 | 190 | |
191 | 191 | } |
@@ -9,11 +9,11 @@ discard block |
||
9 | 9 | * @since 1.8 |
10 | 10 | */ |
11 | 11 | |
12 | -if ( ! defined( 'ABSPATH' ) ) { |
|
12 | +if ( ! defined('ABSPATH')) { |
|
13 | 13 | exit; // Exit if accessed directly |
14 | 14 | } |
15 | 15 | |
16 | -if ( ! class_exists( 'Give_Settings_API' ) ) : |
|
16 | +if ( ! class_exists('Give_Settings_API')) : |
|
17 | 17 | |
18 | 18 | /** |
19 | 19 | * Give_Settings_API. |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | */ |
35 | 35 | public function __construct() { |
36 | 36 | $this->id = 'api'; |
37 | - $this->label = esc_html__( 'API', 'give' ); |
|
37 | + $this->label = esc_html__('API', 'give'); |
|
38 | 38 | |
39 | 39 | parent::__construct(); |
40 | 40 | } |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | */ |
48 | 48 | public function get_settings() { |
49 | 49 | // Get settings. |
50 | - $settings = apply_filters( 'give_settings_api', array( |
|
50 | + $settings = apply_filters('give_settings_api', array( |
|
51 | 51 | array( |
52 | 52 | 'id' => 'give_tools_api', |
53 | 53 | 'type' => 'title', |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | ), |
56 | 56 | array( |
57 | 57 | 'id' => 'api', |
58 | - 'name' => esc_html__( 'API', 'give' ), |
|
58 | + 'name' => esc_html__('API', 'give'), |
|
59 | 59 | 'type' => 'api', |
60 | 60 | ), |
61 | 61 | array( |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | * @since 1.8 |
72 | 72 | * @param array $settings |
73 | 73 | */ |
74 | - $settings = apply_filters( 'give_get_settings_' . $this->id, $settings ); |
|
74 | + $settings = apply_filters('give_get_settings_'.$this->id, $settings); |
|
75 | 75 | |
76 | 76 | // Output. |
77 | 77 | return $settings; |
@@ -9,11 +9,11 @@ discard block |
||
9 | 9 | * @since 1.8 |
10 | 10 | */ |
11 | 11 | |
12 | -if ( ! defined( 'ABSPATH' ) ) { |
|
12 | +if ( ! defined('ABSPATH')) { |
|
13 | 13 | exit; // Exit if accessed directly |
14 | 14 | } |
15 | 15 | |
16 | -if ( ! class_exists( 'Give_Settings_Data' ) ) : |
|
16 | +if ( ! class_exists('Give_Settings_Data')) : |
|
17 | 17 | |
18 | 18 | /** |
19 | 19 | * Give_Settings_Data. |
@@ -35,14 +35,14 @@ discard block |
||
35 | 35 | */ |
36 | 36 | public function __construct() { |
37 | 37 | $this->id = 'data'; |
38 | - $this->label = esc_html__( 'Data', 'give' ); |
|
38 | + $this->label = esc_html__('Data', 'give'); |
|
39 | 39 | |
40 | 40 | parent::__construct(); |
41 | 41 | |
42 | 42 | // Do not use main form for this tab. |
43 | - if( give_get_current_setting_tab() === $this->id ) { |
|
44 | - add_action( "give-tools_open_form", '__return_empty_string' ); |
|
45 | - add_action( "give-tools_close_form", '__return_empty_string' ); |
|
43 | + if (give_get_current_setting_tab() === $this->id) { |
|
44 | + add_action("give-tools_open_form", '__return_empty_string'); |
|
45 | + add_action("give-tools_close_form", '__return_empty_string'); |
|
46 | 46 | } |
47 | 47 | } |
48 | 48 | |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | */ |
55 | 55 | public function get_settings() { |
56 | 56 | // Get settings. |
57 | - $settings = apply_filters( 'give_settings_data', array( |
|
57 | + $settings = apply_filters('give_settings_data', array( |
|
58 | 58 | array( |
59 | 59 | 'id' => 'give_tools_tools', |
60 | 60 | 'type' => 'title', |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | ), |
63 | 63 | array( |
64 | 64 | 'id' => 'api', |
65 | - 'name' => esc_html__( 'Tools', 'give' ), |
|
65 | + 'name' => esc_html__('Tools', 'give'), |
|
66 | 66 | 'type' => 'data', |
67 | 67 | ), |
68 | 68 | array( |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | * @since 1.8 |
79 | 79 | * @param array $settings |
80 | 80 | */ |
81 | - $settings = apply_filters( 'give_get_settings_' . $this->id, $settings ); |
|
81 | + $settings = apply_filters('give_get_settings_'.$this->id, $settings); |
|
82 | 82 | |
83 | 83 | // Output. |
84 | 84 | return $settings; |
@@ -9,11 +9,11 @@ discard block |
||
9 | 9 | * @since 1.8 |
10 | 10 | */ |
11 | 11 | |
12 | -if ( ! defined( 'ABSPATH' ) ) { |
|
12 | +if ( ! defined('ABSPATH')) { |
|
13 | 13 | exit; // Exit if accessed directly |
14 | 14 | } |
15 | 15 | |
16 | -if ( ! class_exists( 'Give_Settings_Import' ) ) { |
|
16 | +if ( ! class_exists('Give_Settings_Import')) { |
|
17 | 17 | |
18 | 18 | /** |
19 | 19 | * Give_Settings_Import. |
@@ -45,23 +45,23 @@ discard block |
||
45 | 45 | */ |
46 | 46 | public function __construct() { |
47 | 47 | $this->id = 'import'; |
48 | - $this->label = __( 'Import', 'give' ); |
|
48 | + $this->label = __('Import', 'give'); |
|
49 | 49 | |
50 | 50 | parent::__construct(); |
51 | 51 | |
52 | 52 | // Will display html of the import donation. |
53 | - add_action( 'give_admin_field_tools_import', array( |
|
53 | + add_action('give_admin_field_tools_import', array( |
|
54 | 54 | 'Give_Settings_Import', |
55 | 55 | 'render_import_field', |
56 | - ), 10, 2 ); |
|
56 | + ), 10, 2); |
|
57 | 57 | |
58 | 58 | // Do not use main form for this tab. |
59 | - if ( give_get_current_setting_tab() === $this->id ) { |
|
60 | - add_action( "give-tools_open_form", '__return_empty_string' ); |
|
61 | - add_action( "give-tools_close_form", '__return_empty_string' ); |
|
59 | + if (give_get_current_setting_tab() === $this->id) { |
|
60 | + add_action("give-tools_open_form", '__return_empty_string'); |
|
61 | + add_action("give-tools_close_form", '__return_empty_string'); |
|
62 | 62 | |
63 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/import/class-give-import-donations.php'; |
|
64 | - require_once GIVE_PLUGIN_DIR . 'includes/admin/tools/import/class-give-import-core-settings.php'; |
|
63 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/import/class-give-import-donations.php'; |
|
64 | + require_once GIVE_PLUGIN_DIR.'includes/admin/tools/import/class-give-import-core-settings.php'; |
|
65 | 65 | } |
66 | 66 | } |
67 | 67 | |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | * @param array $settings |
81 | 81 | */ |
82 | 82 | $settings = apply_filters( |
83 | - 'give_get_settings_' . $this->id, |
|
83 | + 'give_get_settings_'.$this->id, |
|
84 | 84 | array( |
85 | 85 | array( |
86 | 86 | 'id' => 'give_tools_import', |
@@ -89,14 +89,14 @@ discard block |
||
89 | 89 | ), |
90 | 90 | array( |
91 | 91 | 'id' => 'import', |
92 | - 'name' => __( 'Import', 'give' ), |
|
92 | + 'name' => __('Import', 'give'), |
|
93 | 93 | 'type' => 'tools_import', |
94 | 94 | ), |
95 | 95 | array( |
96 | - 'name' => esc_html__( 'Import Docs Link', 'give' ), |
|
96 | + 'name' => esc_html__('Import Docs Link', 'give'), |
|
97 | 97 | 'id' => 'import_docs_link', |
98 | - 'url' => esc_url( 'http://docs.givewp.com/tools-importer' ), |
|
99 | - 'title' => __( 'Import Tab', 'give' ), |
|
98 | + 'url' => esc_url('http://docs.givewp.com/tools-importer'), |
|
99 | + 'title' => __('Import Tab', 'give'), |
|
100 | 100 | 'type' => 'give_docs_link', |
101 | 101 | ), |
102 | 102 | array( |
@@ -120,8 +120,8 @@ discard block |
||
120 | 120 | * @param $field |
121 | 121 | * @param $option_value |
122 | 122 | */ |
123 | - public static function render_import_field( $field, $option_value ) { |
|
124 | - include_once GIVE_PLUGIN_DIR . 'includes/admin/tools/views/html-admin-page-imports.php'; |
|
123 | + public static function render_import_field($field, $option_value) { |
|
124 | + include_once GIVE_PLUGIN_DIR.'includes/admin/tools/views/html-admin-page-imports.php'; |
|
125 | 125 | } |
126 | 126 | } |
127 | 127 | } |
@@ -3,11 +3,11 @@ discard block |
||
3 | 3 | * Admin View: Import Donations |
4 | 4 | */ |
5 | 5 | |
6 | -if ( ! defined( 'ABSPATH' ) ) { |
|
6 | +if ( ! defined('ABSPATH')) { |
|
7 | 7 | exit; |
8 | 8 | } |
9 | 9 | |
10 | -if ( ! current_user_can( 'manage_give_settings' ) ) { |
|
10 | +if ( ! current_user_can('manage_give_settings')) { |
|
11 | 11 | return; |
12 | 12 | } |
13 | 13 | |
@@ -16,11 +16,11 @@ discard block |
||
16 | 16 | * |
17 | 17 | * @since 1.8.13 |
18 | 18 | */ |
19 | -do_action( 'give_tools_import_donations_main_before' ); |
|
19 | +do_action('give_tools_import_donations_main_before'); |
|
20 | 20 | ?> |
21 | 21 | <div id="poststuff"> |
22 | 22 | <div class="postbox"> |
23 | - <h1 class="give-importer-h1" align="center"><?php esc_html_e( 'Import Donations', 'give' ); ?></h1> |
|
23 | + <h1 class="give-importer-h1" align="center"><?php esc_html_e('Import Donations', 'give'); ?></h1> |
|
24 | 24 | <div class="inside give-tools-setting-page-import give-import-donations"> |
25 | 25 | <?php |
26 | 26 | /** |
@@ -28,7 +28,7 @@ discard block |
||
28 | 28 | * |
29 | 29 | * @since 1.8.14 |
30 | 30 | */ |
31 | - do_action( 'give_tools_import_donations_form_before_start' ); |
|
31 | + do_action('give_tools_import_donations_form_before_start'); |
|
32 | 32 | ?> |
33 | 33 | <form method="post" id="give-import-donations-form" class="give-import-form tools-setting-page-import tools-setting-page-import"> |
34 | 34 | |
@@ -38,7 +38,7 @@ discard block |
||
38 | 38 | * |
39 | 39 | * @since 1.8.14 |
40 | 40 | */ |
41 | - do_action( 'give_tools_import_donations_form_start' ); |
|
41 | + do_action('give_tools_import_donations_form_start'); |
|
42 | 42 | ?> |
43 | 43 | |
44 | 44 | <?php |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * |
48 | 48 | * @since 1.8.14 |
49 | 49 | */ |
50 | - do_action( 'give_tools_import_donations_form_end' ); |
|
50 | + do_action('give_tools_import_donations_form_end'); |
|
51 | 51 | ?> |
52 | 52 | </form> |
53 | 53 | <?php |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | * |
57 | 57 | * @since 1.8.14 |
58 | 58 | */ |
59 | - do_action( 'give_tools_import_donations_form_after_end' ); |
|
59 | + do_action('give_tools_import_donations_form_after_end'); |
|
60 | 60 | ?> |
61 | 61 | </div><!-- .inside --> |
62 | 62 | </div><!-- .postbox --> |
@@ -67,4 +67,4 @@ discard block |
||
67 | 67 | * |
68 | 68 | * @since 1.8.13 |
69 | 69 | */ |
70 | -do_action( 'give_tools_import_donations_main_after' ); |
|
70 | +do_action('give_tools_import_donations_main_after'); |
@@ -3,11 +3,11 @@ discard block |
||
3 | 3 | * Admin View: Exports |
4 | 4 | */ |
5 | 5 | |
6 | -if ( ! defined( 'ABSPATH' ) ) { |
|
6 | +if ( ! defined('ABSPATH')) { |
|
7 | 7 | exit; |
8 | 8 | } |
9 | 9 | |
10 | -if ( ! current_user_can( 'manage_give_settings' ) ) { |
|
10 | +if ( ! current_user_can('manage_give_settings')) { |
|
11 | 11 | return; |
12 | 12 | } |
13 | 13 | |
@@ -16,29 +16,29 @@ discard block |
||
16 | 16 | * |
17 | 17 | * @since 1.5 |
18 | 18 | */ |
19 | -do_action( 'give_tools_recount_stats_before' ); |
|
19 | +do_action('give_tools_recount_stats_before'); |
|
20 | 20 | ?> |
21 | 21 | <div id="poststuff"> |
22 | 22 | <div class="postbox"> |
23 | 23 | |
24 | - <h2 class="hndle ui-sortable-handle"><span><?php esc_html_e( 'Recount Stats', 'give' ); ?></span></h2> |
|
24 | + <h2 class="hndle ui-sortable-handle"><span><?php esc_html_e('Recount Stats', 'give'); ?></span></h2> |
|
25 | 25 | |
26 | 26 | <div class="inside recount-stats-controls"> |
27 | - <p><?php esc_html_e( 'Use these tools to recount stats, delete test transactions, or reset stats.', 'give' ); ?></p> |
|
27 | + <p><?php esc_html_e('Use these tools to recount stats, delete test transactions, or reset stats.', 'give'); ?></p> |
|
28 | 28 | <form method="post" id="give-tools-recount-form" class="give-export-form"> |
29 | 29 | |
30 | - <?php wp_nonce_field( 'give_ajax_export', 'give_ajax_export' ); ?> |
|
30 | + <?php wp_nonce_field('give_ajax_export', 'give_ajax_export'); ?> |
|
31 | 31 | |
32 | 32 | <select name="give-export-class" id="recount-stats-type"> |
33 | - <option value="0" selected="selected" disabled="disabled"><?php esc_html_e( 'Please select an option', 'give' ); ?></option> |
|
34 | - <option data-type="recount-stats" value="Give_Tools_Recount_Income"><?php esc_html_e( 'Recalculate Total Donation Income Amount', 'give' ); ?></option> |
|
35 | - <option data-type="recount-form" value="Give_Tools_Recount_Form_Stats"><?php esc_html_e( 'Recalculate Income Amount and Donation Counts for a Form', 'give' ); ?></option> |
|
36 | - <option data-type="recount-all" value="Give_Tools_Recount_All_Stats"><?php esc_html_e( 'Recalculate Income Amount and Donation Counts for All Forms', 'give' ); ?></option> |
|
37 | - <option data-type="recount-donor-stats" value="Give_Tools_Recount_Donor_Stats"><?php esc_html_e( 'Recalculate Donor Statistics', 'give' ); ?></option> |
|
38 | - <option data-type="delete-test-transactions" value="Give_Tools_Delete_Test_Transactions"><?php esc_html_e( 'Delete Test Payments', 'give' ); ?></option> |
|
39 | - <option data-type="delete-test-donors" value="Give_Tools_Delete_Donors"><?php esc_html_e( 'Delete Test Donors and Payments', 'give' ); ?></option> |
|
40 | - <option data-type="delete-import-donors" value="Give_Tools_Import_Donors"><?php esc_html_e( 'Delete Imported Donors and Payments', 'give' ); ?></option> |
|
41 | - <option data-type="reset-stats" value="Give_Tools_Reset_Stats"><?php esc_html_e( 'Delete All Data', 'give' ); ?></option> |
|
33 | + <option value="0" selected="selected" disabled="disabled"><?php esc_html_e('Please select an option', 'give'); ?></option> |
|
34 | + <option data-type="recount-stats" value="Give_Tools_Recount_Income"><?php esc_html_e('Recalculate Total Donation Income Amount', 'give'); ?></option> |
|
35 | + <option data-type="recount-form" value="Give_Tools_Recount_Form_Stats"><?php esc_html_e('Recalculate Income Amount and Donation Counts for a Form', 'give'); ?></option> |
|
36 | + <option data-type="recount-all" value="Give_Tools_Recount_All_Stats"><?php esc_html_e('Recalculate Income Amount and Donation Counts for All Forms', 'give'); ?></option> |
|
37 | + <option data-type="recount-donor-stats" value="Give_Tools_Recount_Donor_Stats"><?php esc_html_e('Recalculate Donor Statistics', 'give'); ?></option> |
|
38 | + <option data-type="delete-test-transactions" value="Give_Tools_Delete_Test_Transactions"><?php esc_html_e('Delete Test Payments', 'give'); ?></option> |
|
39 | + <option data-type="delete-test-donors" value="Give_Tools_Delete_Donors"><?php esc_html_e('Delete Test Donors and Payments', 'give'); ?></option> |
|
40 | + <option data-type="delete-import-donors" value="Give_Tools_Import_Donors"><?php esc_html_e('Delete Imported Donors and Payments', 'give'); ?></option> |
|
41 | + <option data-type="reset-stats" value="Give_Tools_Reset_Stats"><?php esc_html_e('Delete All Data', 'give'); ?></option> |
|
42 | 42 | <?php |
43 | 43 | /** |
44 | 44 | * Fires in the recount stats selectbox. |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * |
48 | 48 | * @since 1.5 |
49 | 49 | */ |
50 | - do_action( 'give_recount_tool_options' ); |
|
50 | + do_action('give_recount_tool_options'); |
|
51 | 51 | ?> |
52 | 52 | </select> |
53 | 53 | |
@@ -56,34 +56,34 @@ discard block |
||
56 | 56 | $args = array( |
57 | 57 | 'class' => 'tools-form-dropdown-recount-form-select', |
58 | 58 | 'name' => 'form_id', |
59 | - 'number' => - 1, |
|
59 | + 'number' => -1, |
|
60 | 60 | 'chosen' => true, |
61 | - 'placeholder' => __( 'Select Form', 'give' ), |
|
61 | + 'placeholder' => __('Select Form', 'give'), |
|
62 | 62 | ); |
63 | - echo Give()->html->forms_dropdown( $args ); |
|
63 | + echo Give()->html->forms_dropdown($args); |
|
64 | 64 | ?> |
65 | 65 | </span> |
66 | 66 | |
67 | 67 | <span class="tools-form-dropdown tools-form-dropdown-delete-import-donors" style="display: none"> |
68 | 68 | <label for="delete-import-donors"> |
69 | 69 | <?php |
70 | - echo Give()->html->checkbox( array( |
|
70 | + echo Give()->html->checkbox(array( |
|
71 | 71 | 'name' => 'delete-import-donors' |
72 | - ) ); |
|
73 | - _e( 'Delete imported WordPress users', 'give' ); |
|
72 | + )); |
|
73 | + _e('Delete imported WordPress users', 'give'); |
|
74 | 74 | ?> |
75 | 75 | </label> |
76 | 76 | </span> |
77 | 77 | |
78 | - <input type="submit" id="recount-stats-submit" value="<?php esc_attr_e( 'Submit', 'give' ); ?>" class="button-secondary"/> |
|
78 | + <input type="submit" id="recount-stats-submit" value="<?php esc_attr_e('Submit', 'give'); ?>" class="button-secondary"/> |
|
79 | 79 | |
80 | 80 | <br/> |
81 | 81 | |
82 | 82 | <span class="give-recount-stats-descriptions"> |
83 | - <span id="recount-stats"><?php esc_html_e( 'Recalculates the overall donation income amount.', 'give' ); ?></span> |
|
84 | - <span id="recount-form"><?php esc_html_e( 'Recalculates the donation and income stats for a specific form.', 'give' ); ?></span> |
|
85 | - <span id="recount-all"><?php esc_html_e( 'Recalculates the earnings and sales stats for all forms.', 'give' ); ?></span> |
|
86 | - <span id="recount-customer-stats"><?php esc_html_e( 'Recalculates the lifetime value and donation counts for all donors.', 'give' ); ?></span> |
|
83 | + <span id="recount-stats"><?php esc_html_e('Recalculates the overall donation income amount.', 'give'); ?></span> |
|
84 | + <span id="recount-form"><?php esc_html_e('Recalculates the donation and income stats for a specific form.', 'give'); ?></span> |
|
85 | + <span id="recount-all"><?php esc_html_e('Recalculates the earnings and sales stats for all forms.', 'give'); ?></span> |
|
86 | + <span id="recount-customer-stats"><?php esc_html_e('Recalculates the lifetime value and donation counts for all donors.', 'give'); ?></span> |
|
87 | 87 | <?php |
88 | 88 | /** |
89 | 89 | * Fires in the recount stats description area. |
@@ -92,10 +92,10 @@ discard block |
||
92 | 92 | * |
93 | 93 | * @since 1.5 |
94 | 94 | */ |
95 | - do_action( 'give_recount_tool_descriptions' ); |
|
95 | + do_action('give_recount_tool_descriptions'); |
|
96 | 96 | ?> |
97 | - <span id="delete-test-transactions"><?php _e( '<strong>Deletes</strong> all TEST donations, donors, and related log entries.', 'give' ); ?></span> |
|
98 | - <span id="reset-stats"><?php _e( '<strong>Deletes</strong> ALL donations, donors, and related log entries regardless of test or live mode.', 'give' ); ?></span> |
|
97 | + <span id="delete-test-transactions"><?php _e('<strong>Deletes</strong> all TEST donations, donors, and related log entries.', 'give'); ?></span> |
|
98 | + <span id="reset-stats"><?php _e('<strong>Deletes</strong> ALL donations, donors, and related log entries regardless of test or live mode.', 'give'); ?></span> |
|
99 | 99 | </span> |
100 | 100 | |
101 | 101 | <span class="spinner"></span> |
@@ -109,7 +109,7 @@ discard block |
||
109 | 109 | * |
110 | 110 | * @since 1.5 |
111 | 111 | */ |
112 | - do_action( 'give_tools_recount_forms' ); |
|
112 | + do_action('give_tools_recount_forms'); |
|
113 | 113 | ?> |
114 | 114 | </div><!-- .inside --> |
115 | 115 | </div><!-- .postbox --> |
@@ -120,4 +120,4 @@ discard block |
||
120 | 120 | * |
121 | 121 | * @since 1.5 |
122 | 122 | */ |
123 | -do_action( 'give_tools_recount_stats_after' ); |
|
123 | +do_action('give_tools_recount_stats_after'); |
@@ -3,7 +3,7 @@ discard block |
||
3 | 3 | * Admin View: Imports |
4 | 4 | */ |
5 | 5 | |
6 | -if ( ! defined( 'ABSPATH' ) ) { |
|
6 | +if ( ! defined('ABSPATH')) { |
|
7 | 7 | exit; |
8 | 8 | } ?> |
9 | 9 | |
@@ -18,14 +18,14 @@ discard block |
||
18 | 18 | * |
19 | 19 | * @since 1.8.14 |
20 | 20 | */ |
21 | - do_action( 'give_tools_tab_import_content_top' ); |
|
21 | + do_action('give_tools_tab_import_content_top'); |
|
22 | 22 | ?> |
23 | 23 | |
24 | 24 | <table class="widefat Import-options-table give-table"> |
25 | 25 | <thead> |
26 | 26 | <tr> |
27 | - <th scope="col"><?php esc_html_e( 'Import Type', 'give' ); ?></th> |
|
28 | - <th scope="col"><?php esc_html_e( 'Import Options', 'give' ); ?></th> |
|
27 | + <th scope="col"><?php esc_html_e('Import Type', 'give'); ?></th> |
|
28 | + <th scope="col"><?php esc_html_e('Import Options', 'give'); ?></th> |
|
29 | 29 | </tr> |
30 | 30 | </thead> |
31 | 31 | <tbody> |
@@ -38,19 +38,19 @@ discard block |
||
38 | 38 | * |
39 | 39 | * @since 1.8.14 |
40 | 40 | */ |
41 | - do_action( 'give_tools_tab_import_table_top' ); |
|
41 | + do_action('give_tools_tab_import_table_top'); |
|
42 | 42 | ?> |
43 | 43 | |
44 | 44 | <tr class="give-Import-pdf-sales-earnings"> |
45 | 45 | <td scope="row" class="row-title"> |
46 | 46 | <h3> |
47 | - <span><?php esc_html_e( 'Import Donations', 'give' ); ?></span> |
|
47 | + <span><?php esc_html_e('Import Donations', 'give'); ?></span> |
|
48 | 48 | </h3> |
49 | - <p><?php esc_html_e( 'Import a CSV of Donations.', 'give' ); ?></p> |
|
49 | + <p><?php esc_html_e('Import a CSV of Donations.', 'give'); ?></p> |
|
50 | 50 | </td> |
51 | 51 | <td> |
52 | - <a class="button" href="<?php echo add_query_arg( array( 'importer-type' => 'import_donations' ) ); ?>"> |
|
53 | - <?php esc_html_e( 'Import CSV', 'give' ); ?> |
|
52 | + <a class="button" href="<?php echo add_query_arg(array('importer-type' => 'import_donations')); ?>"> |
|
53 | + <?php esc_html_e('Import CSV', 'give'); ?> |
|
54 | 54 | </a> |
55 | 55 | </td> |
56 | 56 | </tr> |
@@ -58,13 +58,13 @@ discard block |
||
58 | 58 | <tr class="give-import-core-settings"> |
59 | 59 | <td scope="row" class="row-title"> |
60 | 60 | <h3> |
61 | - <span><?php esc_html_e( 'Import Give Settings', 'give' ); ?></span> |
|
61 | + <span><?php esc_html_e('Import Give Settings', 'give'); ?></span> |
|
62 | 62 | </h3> |
63 | - <p><?php esc_html_e( 'Import Give\'s settings in JSON format.', 'give' ); ?></p> |
|
63 | + <p><?php esc_html_e('Import Give\'s settings in JSON format.', 'give'); ?></p> |
|
64 | 64 | </td> |
65 | 65 | <td> |
66 | - <a class="button" href="<?php echo add_query_arg( array( 'importer-type' => 'import_core_setting' ) ); ?>"> |
|
67 | - <?php esc_html_e( 'Import JSON', 'give' ); ?> |
|
66 | + <a class="button" href="<?php echo add_query_arg(array('importer-type' => 'import_core_setting')); ?>"> |
|
67 | + <?php esc_html_e('Import JSON', 'give'); ?> |
|
68 | 68 | </a> |
69 | 69 | </td> |
70 | 70 | </tr> |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | * |
79 | 79 | * @since 1.8.14 |
80 | 80 | */ |
81 | - do_action( 'give_tools_tab_import_table_bottom' ); |
|
81 | + do_action('give_tools_tab_import_table_bottom'); |
|
82 | 82 | ?> |
83 | 83 | </tbody> |
84 | 84 | </table> |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | * |
90 | 90 | * @since 1.8.14 |
91 | 91 | */ |
92 | - do_action( 'give_tools_tab_import_content_bottom' ); |
|
92 | + do_action('give_tools_tab_import_content_bottom'); |
|
93 | 93 | ?> |
94 | 94 | |
95 | 95 | </div> |