@@ -3,7 +3,7 @@ discard block |
||
3 | 3 | * Admin View: System Info |
4 | 4 | */ |
5 | 5 | |
6 | -if ( ! defined( 'ABSPATH' ) ) { |
|
6 | +if ( ! defined('ABSPATH')) { |
|
7 | 7 | exit; |
8 | 8 | } |
9 | 9 | |
@@ -25,10 +25,10 @@ discard block |
||
25 | 25 | ?> |
26 | 26 | |
27 | 27 | <div class="give-debug-report-wrapper"> |
28 | - <p class="give-debug-report-text"><?php echo sprintf(__( 'Please copy and paste this information in your ticket when contacting support:', 'give' )); ?> </p> |
|
28 | + <p class="give-debug-report-text"><?php echo sprintf(__('Please copy and paste this information in your ticket when contacting support:', 'give')); ?> </p> |
|
29 | 29 | <div class="give-debug-report-actions"> |
30 | - <a class="button-primary js-give-debug-report-button" href="#"><?php _e( 'Get System Report', 'give' ); ?></a> |
|
31 | - <a class="button-secondary docs" href="http://docs.givewp.com/settings-system-info" target="_blank"><?php _e( 'Understanding the System Report', 'give' ); ?> <span class="dashicons dashicons-external"></span></a> |
|
30 | + <a class="button-primary js-give-debug-report-button" href="#"><?php _e('Get System Report', 'give'); ?></a> |
|
31 | + <a class="button-secondary docs" href="http://docs.givewp.com/settings-system-info" target="_blank"><?php _e('Understanding the System Report', 'give'); ?> <span class="dashicons dashicons-external"></span></a> |
|
32 | 32 | </div> |
33 | 33 | <div class="give-debug-report js-give-debug-report"> |
34 | 34 | <textarea readonly="readonly"></textarea> |
@@ -38,56 +38,56 @@ discard block |
||
38 | 38 | <table class="give-status-table widefat" cellspacing="0" id="status"> |
39 | 39 | <thead> |
40 | 40 | <tr> |
41 | - <th colspan="3" data-export-label="WordPress Environment"><h2><?php _e( 'WordPress Environment', 'give' ); ?></h2></th> |
|
41 | + <th colspan="3" data-export-label="WordPress Environment"><h2><?php _e('WordPress Environment', 'give'); ?></h2></th> |
|
42 | 42 | </tr> |
43 | 43 | </thead> |
44 | 44 | <tbody> |
45 | 45 | <tr> |
46 | - <td data-export-label="Home URL"><?php _e( 'Home URL', 'give' ); ?>:</td> |
|
47 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The URL of your site\'s homepage.', 'give' ) ); ?></td> |
|
48 | - <td><?php form_option( 'home' ); ?></td> |
|
46 | + <td data-export-label="Home URL"><?php _e('Home URL', 'give'); ?>:</td> |
|
47 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The URL of your site\'s homepage.', 'give')); ?></td> |
|
48 | + <td><?php form_option('home'); ?></td> |
|
49 | 49 | </tr> |
50 | 50 | <tr> |
51 | - <td data-export-label="Site URL"><?php _e( 'Site URL', 'give' ); ?>:</td> |
|
52 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The root URL of your site.', 'give' ) ); ?></td> |
|
53 | - <td><?php form_option( 'siteurl' ); ?></td> |
|
51 | + <td data-export-label="Site URL"><?php _e('Site URL', 'give'); ?>:</td> |
|
52 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The root URL of your site.', 'give')); ?></td> |
|
53 | + <td><?php form_option('siteurl'); ?></td> |
|
54 | 54 | </tr> |
55 | 55 | <tr> |
56 | - <td data-export-label="WP Version"><?php _e( 'WP Version', 'give' ); ?>:</td> |
|
57 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of WordPress installed on your site.', 'give' ) ); ?></td> |
|
58 | - <td><?php bloginfo( 'version' ); ?></td> |
|
56 | + <td data-export-label="WP Version"><?php _e('WP Version', 'give'); ?>:</td> |
|
57 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of WordPress installed on your site.', 'give')); ?></td> |
|
58 | + <td><?php bloginfo('version'); ?></td> |
|
59 | 59 | </tr> |
60 | 60 | <tr> |
61 | - <td data-export-label="WP Multisite"><?php _e( 'WP Multisite', 'give' ); ?>:</td> |
|
62 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether or not you have WordPress Multisite enabled.', 'give' ) ); ?></td> |
|
63 | - <td><?php if ( is_multisite() ) echo '<span class="dashicons dashicons-yes"></span>'; else echo '–'; ?></td> |
|
61 | + <td data-export-label="WP Multisite"><?php _e('WP Multisite', 'give'); ?>:</td> |
|
62 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether or not you have WordPress Multisite enabled.', 'give')); ?></td> |
|
63 | + <td><?php if (is_multisite()) echo '<span class="dashicons dashicons-yes"></span>'; else echo '–'; ?></td> |
|
64 | 64 | |
65 | 65 | </tr> |
66 | 66 | <tr> |
67 | - <td data-export-label="WP Memory Limit"><?php _e( 'WP Memory Limit', 'give' ); ?>:</td> |
|
68 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The maximum amount of memory (RAM) that your site can use at one time.', 'give' ) ); ?></td> |
|
67 | + <td data-export-label="WP Memory Limit"><?php _e('WP Memory Limit', 'give'); ?>:</td> |
|
68 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The maximum amount of memory (RAM) that your site can use at one time.', 'give')); ?></td> |
|
69 | 69 | <td> |
70 | 70 | <?php |
71 | - $memory = give_let_to_num( WP_MEMORY_LIMIT ); |
|
71 | + $memory = give_let_to_num(WP_MEMORY_LIMIT); |
|
72 | 72 | |
73 | - if ( function_exists( 'memory_get_usage' ) ) { |
|
74 | - $system_memory = give_let_to_num( @ini_get( 'memory_limit' ) ); |
|
75 | - $memory = max( $memory, $system_memory ); |
|
73 | + if (function_exists('memory_get_usage')) { |
|
74 | + $system_memory = give_let_to_num(@ini_get('memory_limit')); |
|
75 | + $memory = max($memory, $system_memory); |
|
76 | 76 | } |
77 | 77 | |
78 | - if ( $memory < 67108864 ) { |
|
79 | - echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( '%s - We recommend setting memory to at least 64 MB. See: %s', 'give' ), size_format( $memory ), '<a href="https://codex.wordpress.org/Editing_wp-config.php#Increasing_memory_allocated_to_PHP" target="_blank">' . __( 'Increasing memory allocated to PHP', 'give' ) . '</a>' ) . '</mark>'; |
|
78 | + if ($memory < 67108864) { |
|
79 | + echo '<mark class="error"><span class="dashicons dashicons-warning"></span> '.sprintf(__('%s - We recommend setting memory to at least 64 MB. See: %s', 'give'), size_format($memory), '<a href="https://codex.wordpress.org/Editing_wp-config.php#Increasing_memory_allocated_to_PHP" target="_blank">'.__('Increasing memory allocated to PHP', 'give').'</a>').'</mark>'; |
|
80 | 80 | } else { |
81 | - echo '<mark class="yes">' . size_format( $memory ) . '</mark>'; |
|
81 | + echo '<mark class="yes">'.size_format($memory).'</mark>'; |
|
82 | 82 | } |
83 | 83 | ?> |
84 | 84 | </td> |
85 | 85 | </tr> |
86 | 86 | <tr> |
87 | - <td data-export-label="WP Debug Mode"><?php _e( 'WP Debug Mode', 'give' ); ?>:</td> |
|
88 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Displays whether or not WordPress is in Debug Mode.', 'give' ) ); ?></td> |
|
87 | + <td data-export-label="WP Debug Mode"><?php _e('WP Debug Mode', 'give'); ?>:</td> |
|
88 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Displays whether or not WordPress is in Debug Mode.', 'give')); ?></td> |
|
89 | 89 | <td> |
90 | - <?php if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) : ?> |
|
90 | + <?php if (defined('WP_DEBUG') && WP_DEBUG) : ?> |
|
91 | 91 | <mark class="yes"><span class="dashicons dashicons-yes"></span></mark> |
92 | 92 | <?php else : ?> |
93 | 93 | <mark class="no">–</mark> |
@@ -95,10 +95,10 @@ discard block |
||
95 | 95 | </td> |
96 | 96 | </tr> |
97 | 97 | <tr> |
98 | - <td data-export-label="WP Cron"><?php _e( 'WP Cron', 'give' ); ?>:</td> |
|
99 | - <td class="help"><?php echo Give()->tooltips->render( __( 'Displays whether or not WP Cron Jobs are enabled.', 'give' ) ); ?></td> |
|
98 | + <td data-export-label="WP Cron"><?php _e('WP Cron', 'give'); ?>:</td> |
|
99 | + <td class="help"><?php echo Give()->tooltips->render(__('Displays whether or not WP Cron Jobs are enabled.', 'give')); ?></td> |
|
100 | 100 | <td> |
101 | - <?php if ( defined( 'DISABLE_WP_CRON' ) && DISABLE_WP_CRON ) : ?> |
|
101 | + <?php if (defined('DISABLE_WP_CRON') && DISABLE_WP_CRON) : ?> |
|
102 | 102 | <mark class="no">–</mark> |
103 | 103 | <?php else : ?> |
104 | 104 | <mark class="yes"><span class="dashicons dashicons-yes"></span></mark> |
@@ -106,60 +106,60 @@ discard block |
||
106 | 106 | </td> |
107 | 107 | </tr> |
108 | 108 | <tr> |
109 | - <td data-export-label="Language"><?php _e( 'Language', 'give' ); ?>:</td> |
|
110 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The current language used by WordPress. Default = English', 'give' ) ); ?></td> |
|
109 | + <td data-export-label="Language"><?php _e('Language', 'give'); ?>:</td> |
|
110 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The current language used by WordPress. Default = English', 'give')); ?></td> |
|
111 | 111 | <td><?php echo get_locale(); ?></td> |
112 | 112 | </tr> |
113 | 113 | <tr> |
114 | - <td data-export-label="Permalink Structure"><?php _e( 'Permalink Structure', 'give' ); ?>:</td> |
|
115 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The permalink structure as defined in Settings.', 'give' ) ); ?></td> |
|
116 | - <td><?php echo esc_html( get_option( 'permalink_structure', __( 'Default', 'give' ) ) ); ?></td> |
|
114 | + <td data-export-label="Permalink Structure"><?php _e('Permalink Structure', 'give'); ?>:</td> |
|
115 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The permalink structure as defined in Settings.', 'give')); ?></td> |
|
116 | + <td><?php echo esc_html(get_option('permalink_structure', __('Default', 'give'))); ?></td> |
|
117 | 117 | </tr> |
118 | 118 | <tr> |
119 | - <td data-export-label="Show on Front"><?php _e( 'Show on Front', 'give' ); ?>:</td> |
|
120 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether your front page is set to show posts or a static page.', 'give' ) ); ?></td> |
|
121 | - <td><?php echo esc_html( get_option( 'show_on_front', '–' ) ); ?></td> |
|
119 | + <td data-export-label="Show on Front"><?php _e('Show on Front', 'give'); ?>:</td> |
|
120 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether your front page is set to show posts or a static page.', 'give')); ?></td> |
|
121 | + <td><?php echo esc_html(get_option('show_on_front', '–')); ?></td> |
|
122 | 122 | </tr> |
123 | - <?php if ( 'page' === get_option( 'show_on_front' ) ) : ?> |
|
123 | + <?php if ('page' === get_option('show_on_front')) : ?> |
|
124 | 124 | <?php |
125 | - $front_page_id = absint( get_option( 'page_on_front' ) ); |
|
126 | - $blog_page_id = absint( get_option( 'page_for_posts' ) ); |
|
125 | + $front_page_id = absint(get_option('page_on_front')); |
|
126 | + $blog_page_id = absint(get_option('page_for_posts')); |
|
127 | 127 | ?> |
128 | 128 | <tr> |
129 | - <td data-export-label="Page on Front"><?php _e( 'Page on Front', 'give' ); ?>:</td> |
|
130 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The page set to display as your front page.', 'give' ) ); ?></td> |
|
131 | - <td><?php echo 0 !== $front_page_id ? esc_html( get_the_title( $front_page_id ) . ' (#' . $front_page_id . ')' ) : __( 'Unset', 'give' ); ?></td> |
|
129 | + <td data-export-label="Page on Front"><?php _e('Page on Front', 'give'); ?>:</td> |
|
130 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The page set to display as your front page.', 'give')); ?></td> |
|
131 | + <td><?php echo 0 !== $front_page_id ? esc_html(get_the_title($front_page_id).' (#'.$front_page_id.')') : __('Unset', 'give'); ?></td> |
|
132 | 132 | </tr> |
133 | 133 | <tr> |
134 | - <td data-export-label="Page for Posts"><?php _e( 'Page for Posts', 'give' ); ?>:</td> |
|
135 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The page set to display your posts.', 'give' ) ); ?></td> |
|
136 | - <td><?php echo 0 !== $blog_page_id ? esc_html( get_the_title( $blog_page_id ) . ' (#' . $blog_page_id . ')' ) : __( 'Unset', 'give' ); ?></td> |
|
134 | + <td data-export-label="Page for Posts"><?php _e('Page for Posts', 'give'); ?>:</td> |
|
135 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The page set to display your posts.', 'give')); ?></td> |
|
136 | + <td><?php echo 0 !== $blog_page_id ? esc_html(get_the_title($blog_page_id).' (#'.$blog_page_id.')') : __('Unset', 'give'); ?></td> |
|
137 | 137 | </tr> |
138 | - <?php endif;?> |
|
138 | + <?php endif; ?> |
|
139 | 139 | <tr> |
140 | - <td data-export-label="Table Prefix Length"><?php _e( 'Table Prefix', 'give' ); ?>:</td> |
|
141 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The table prefix used in your WordPress database.', 'give' ) ); ?></td> |
|
142 | - <td><?php echo esc_html( $wpdb->prefix ); ?></td> |
|
140 | + <td data-export-label="Table Prefix Length"><?php _e('Table Prefix', 'give'); ?>:</td> |
|
141 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The table prefix used in your WordPress database.', 'give')); ?></td> |
|
142 | + <td><?php echo esc_html($wpdb->prefix); ?></td> |
|
143 | 143 | </tr> |
144 | 144 | <tr> |
145 | - <td data-export-label="Table Prefix Length"><?php _e( 'Table Prefix Length', 'give' ); ?>:</td> |
|
146 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The length of the table prefix used in your WordPress database.', 'give' ) ); ?></td> |
|
147 | - <td><?php echo esc_html( strlen( $wpdb->prefix ) ); ?></td> |
|
145 | + <td data-export-label="Table Prefix Length"><?php _e('Table Prefix Length', 'give'); ?>:</td> |
|
146 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The length of the table prefix used in your WordPress database.', 'give')); ?></td> |
|
147 | + <td><?php echo esc_html(strlen($wpdb->prefix)); ?></td> |
|
148 | 148 | </tr> |
149 | 149 | <tr> |
150 | - <td data-export-label="Table Prefix Status"><?php _e( 'Table Prefix Status', 'give' ); ?>:</td> |
|
151 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The status of the table prefix used in your WordPress database.', 'give' ) ); ?></td> |
|
152 | - <td><?php echo strlen( $wpdb->prefix ) > 16 ? esc_html( 'Error: Too long', 'give' ) : esc_html( 'Acceptable', 'give' ); ?></td> |
|
150 | + <td data-export-label="Table Prefix Status"><?php _e('Table Prefix Status', 'give'); ?>:</td> |
|
151 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The status of the table prefix used in your WordPress database.', 'give')); ?></td> |
|
152 | + <td><?php echo strlen($wpdb->prefix) > 16 ? esc_html('Error: Too long', 'give') : esc_html('Acceptable', 'give'); ?></td> |
|
153 | 153 | </tr> |
154 | 154 | <tr> |
155 | - <td data-export-label="Admin AJAX"><?php _e( 'Admin AJAX', 'give' ); ?>:</td> |
|
156 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether Admin AJAX is accessible.', 'give' ) ); ?></td> |
|
157 | - <td><?php echo give_test_ajax_works() ? __( 'Accessible', 'give' ) : __( 'Inaccessible', 'give' ); ?></td> |
|
155 | + <td data-export-label="Admin AJAX"><?php _e('Admin AJAX', 'give'); ?>:</td> |
|
156 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether Admin AJAX is accessible.', 'give')); ?></td> |
|
157 | + <td><?php echo give_test_ajax_works() ? __('Accessible', 'give') : __('Inaccessible', 'give'); ?></td> |
|
158 | 158 | </tr> |
159 | 159 | <tr> |
160 | - <td data-export-label="Registered Post Statuses"><?php _e( 'Registered Post Statuses', 'give' ); ?>:</td> |
|
161 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'A list of all registered post statuses.', 'give' ) ); ?></td> |
|
162 | - <td><?php echo esc_html( implode( ', ', get_post_stati() ) ); ?></td> |
|
160 | + <td data-export-label="Registered Post Statuses"><?php _e('Registered Post Statuses', 'give'); ?>:</td> |
|
161 | + <td class="help"><?php echo Give()->tooltips->render_help(__('A list of all registered post statuses.', 'give')); ?></td> |
|
162 | + <td><?php echo esc_html(implode(', ', get_post_stati())); ?></td> |
|
163 | 163 | </tr> |
164 | 164 | </tbody> |
165 | 165 | </table> |
@@ -167,97 +167,97 @@ discard block |
||
167 | 167 | <table class="give-status-table widefat" cellspacing="0"> |
168 | 168 | <thead> |
169 | 169 | <tr> |
170 | - <th colspan="3" data-export-label="Server Environment"><h2><?php _e( 'Server Environment', 'give' ); ?></h2></th> |
|
170 | + <th colspan="3" data-export-label="Server Environment"><h2><?php _e('Server Environment', 'give'); ?></h2></th> |
|
171 | 171 | </tr> |
172 | 172 | </thead> |
173 | 173 | <tbody> |
174 | 174 | <tr> |
175 | - <td data-export-label="Hosting Provider"><?php _e( 'Hosting Provider', 'give' ); ?>:</td> |
|
176 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The hosting provider for this WordPress installation.', 'give' ) ); ?></td> |
|
177 | - <td><?php echo give_get_host() ? esc_html( give_get_host() ) : __( 'Unknown', 'give' ); ?></td> |
|
175 | + <td data-export-label="Hosting Provider"><?php _e('Hosting Provider', 'give'); ?>:</td> |
|
176 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The hosting provider for this WordPress installation.', 'give')); ?></td> |
|
177 | + <td><?php echo give_get_host() ? esc_html(give_get_host()) : __('Unknown', 'give'); ?></td> |
|
178 | 178 | </tr> |
179 | 179 | <tr> |
180 | - <td data-export-label="TLS Connection"><?php _e( 'TLS Connection', 'give' ); ?>:</td> |
|
181 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Most payment gateway APIs only support connections using the TLS 1.2 security protocol.', 'give' ) ); ?></td> |
|
180 | + <td data-export-label="TLS Connection"><?php _e('TLS Connection', 'give'); ?>:</td> |
|
181 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Most payment gateway APIs only support connections using the TLS 1.2 security protocol.', 'give')); ?></td> |
|
182 | 182 | <td> |
183 | 183 | <?php |
184 | - $tls_check = wp_remote_post( 'https://www.howsmyssl.com/a/check' ); |
|
185 | - if ( ! is_wp_error( $tls_check ) ) { |
|
186 | - $tls_check = json_decode( wp_remote_retrieve_body( $tls_check ) ); |
|
184 | + $tls_check = wp_remote_post('https://www.howsmyssl.com/a/check'); |
|
185 | + if ( ! is_wp_error($tls_check)) { |
|
186 | + $tls_check = json_decode(wp_remote_retrieve_body($tls_check)); |
|
187 | 187 | /* translators: %s: SSL connection response */ |
188 | - printf( __('Connection uses %s', 'give'), esc_html( $tls_check->tls_version )) ; |
|
188 | + printf(__('Connection uses %s', 'give'), esc_html($tls_check->tls_version)); |
|
189 | 189 | } |
190 | 190 | ?> |
191 | 191 | </td> |
192 | 192 | </tr> |
193 | 193 | <tr> |
194 | - <td data-export-label="TLS Connection"><?php _e( 'TLS Rating', 'give' ); ?>:</td> |
|
195 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The server\'s connection as rated by https://www.howsmyssl.com/', 'give' ) ); ?></td> |
|
194 | + <td data-export-label="TLS Connection"><?php _e('TLS Rating', 'give'); ?>:</td> |
|
195 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The server\'s connection as rated by https://www.howsmyssl.com/', 'give')); ?></td> |
|
196 | 196 | <td> |
197 | 197 | <?php |
198 | - if ( ! is_wp_error( $tls_check ) ) { |
|
199 | - esc_html_e( $tls_check->rating); |
|
198 | + if ( ! is_wp_error($tls_check)) { |
|
199 | + esc_html_e($tls_check->rating); |
|
200 | 200 | } |
201 | 201 | ?> |
202 | 202 | </td> |
203 | 203 | </tr> |
204 | 204 | <tr> |
205 | - <td data-export-label="Server Info"><?php _e( 'Server Info', 'give' ); ?>:</td> |
|
206 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Information about the web server that is currently hosting your site.', 'give' ) ); ?></td> |
|
207 | - <td><?php echo esc_html( $_SERVER['SERVER_SOFTWARE'] ); ?></td> |
|
205 | + <td data-export-label="Server Info"><?php _e('Server Info', 'give'); ?>:</td> |
|
206 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Information about the web server that is currently hosting your site.', 'give')); ?></td> |
|
207 | + <td><?php echo esc_html($_SERVER['SERVER_SOFTWARE']); ?></td> |
|
208 | 208 | </tr> |
209 | 209 | <tr> |
210 | - <td data-export-label="PHP Version"><?php _e( 'PHP Version', 'give' ); ?>:</td> |
|
211 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of PHP installed on your hosting server.', 'give' ) ); ?></td> |
|
210 | + <td data-export-label="PHP Version"><?php _e('PHP Version', 'give'); ?>:</td> |
|
211 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of PHP installed on your hosting server.', 'give')); ?></td> |
|
212 | 212 | <td> |
213 | 213 | <?php |
214 | 214 | // Check if phpversion function exists. |
215 | - if ( function_exists( 'phpversion' ) ) { |
|
215 | + if (function_exists('phpversion')) { |
|
216 | 216 | $php_version = phpversion(); |
217 | 217 | |
218 | - if ( version_compare( $php_version, '5.6', '<' ) ) { |
|
219 | - echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( '%s - We recommend a minimum PHP version of 5.6. See: %s', 'give' ), esc_html( $php_version ), '<a href="http://docs.givewp.com/settings-system-info" target="_blank">' . __( 'PHP Requirements in Give', 'give' ) . '</a>' ) . '</mark>'; |
|
218 | + if (version_compare($php_version, '5.6', '<')) { |
|
219 | + echo '<mark class="error"><span class="dashicons dashicons-warning"></span> '.sprintf(__('%s - We recommend a minimum PHP version of 5.6. See: %s', 'give'), esc_html($php_version), '<a href="http://docs.givewp.com/settings-system-info" target="_blank">'.__('PHP Requirements in Give', 'give').'</a>').'</mark>'; |
|
220 | 220 | } else { |
221 | - echo '<mark class="yes">' . esc_html( $php_version ) . '</mark>'; |
|
221 | + echo '<mark class="yes">'.esc_html($php_version).'</mark>'; |
|
222 | 222 | } |
223 | 223 | } else { |
224 | - _e( "Couldn't determine PHP version because phpversion() doesn't exist.", 'give' ); |
|
224 | + _e("Couldn't determine PHP version because phpversion() doesn't exist.", 'give'); |
|
225 | 225 | } |
226 | 226 | ?></td> |
227 | 227 | </tr> |
228 | - <?php if ( function_exists( 'ini_get' ) ) : ?> |
|
228 | + <?php if (function_exists('ini_get')) : ?> |
|
229 | 229 | <tr> |
230 | - <td data-export-label="PHP Post Max Size"><?php _e( 'PHP Post Max Size', 'give' ); ?>:</td> |
|
231 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The largest filesize that can be contained in one post.', 'give' ) ); ?></td> |
|
232 | - <td><?php echo size_format( give_let_to_num( ini_get( 'post_max_size' ) ) ); ?></td> |
|
230 | + <td data-export-label="PHP Post Max Size"><?php _e('PHP Post Max Size', 'give'); ?>:</td> |
|
231 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The largest filesize that can be contained in one post.', 'give')); ?></td> |
|
232 | + <td><?php echo size_format(give_let_to_num(ini_get('post_max_size'))); ?></td> |
|
233 | 233 | </tr> |
234 | 234 | <tr> |
235 | - <td data-export-label="PHP Time Limit"><?php _e( 'PHP Time Limit', 'give' ); ?>:</td> |
|
236 | - <td class="help"><?php echo Give() ->tooltips->render_help( __( 'The amount of time (in seconds) that your site will spend on a single operation before timing out (to avoid server lockups).', 'give' ) ); ?></td> |
|
237 | - <td><?php echo ini_get( 'max_execution_time' ); ?></td> |
|
235 | + <td data-export-label="PHP Time Limit"><?php _e('PHP Time Limit', 'give'); ?>:</td> |
|
236 | + <td class="help"><?php echo Give() ->tooltips->render_help(__('The amount of time (in seconds) that your site will spend on a single operation before timing out (to avoid server lockups).', 'give')); ?></td> |
|
237 | + <td><?php echo ini_get('max_execution_time'); ?></td> |
|
238 | 238 | </tr> |
239 | 239 | <tr> |
240 | - <td data-export-label="PHP Max Input Vars"><?php _e( 'PHP Max Input Vars', 'give' ); ?>:</td> |
|
241 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The maximum number of variables your server can use for a single function to avoid overloads.', 'give' ) ); ?></td> |
|
242 | - <td><?php echo ini_get( 'max_input_vars' ); ?></td> |
|
240 | + <td data-export-label="PHP Max Input Vars"><?php _e('PHP Max Input Vars', 'give'); ?>:</td> |
|
241 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The maximum number of variables your server can use for a single function to avoid overloads.', 'give')); ?></td> |
|
242 | + <td><?php echo ini_get('max_input_vars'); ?></td> |
|
243 | 243 | </tr> |
244 | 244 | <tr> |
245 | - <td data-export-label="PHP Max Upload Size"><?php _e( 'PHP Max Upload Size', 'give' ); ?>:</td> |
|
246 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The largest filesize that can be uploaded to your WordPress installation.', 'give' ) ); ?></td> |
|
247 | - <td><?php echo size_format( wp_max_upload_size() ); ?></td> |
|
245 | + <td data-export-label="PHP Max Upload Size"><?php _e('PHP Max Upload Size', 'give'); ?>:</td> |
|
246 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The largest filesize that can be uploaded to your WordPress installation.', 'give')); ?></td> |
|
247 | + <td><?php echo size_format(wp_max_upload_size()); ?></td> |
|
248 | 248 | </tr> |
249 | 249 | <tr> |
250 | - <td data-export-label="cURL Version"><?php _e( 'cURL Version', 'give' ); ?>:</td> |
|
251 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of cURL installed on your server.', 'give' ) ); ?></td> |
|
250 | + <td data-export-label="cURL Version"><?php _e('cURL Version', 'give'); ?>:</td> |
|
251 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of cURL installed on your server.', 'give')); ?></td> |
|
252 | 252 | <td> |
253 | 253 | <?php |
254 | - if ( function_exists( 'curl_version' ) ) { |
|
254 | + if (function_exists('curl_version')) { |
|
255 | 255 | $curl_version = curl_version(); |
256 | 256 | |
257 | - if ( version_compare( $curl_version['version'], '7.40', '<' ) ) { |
|
258 | - echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( '%s - We recommend a minimum cURL version of 7.40.', 'give' ), esc_html( $curl_version['version'] . ', ' . $curl_version['ssl_version'] ) ) . '</mark>'; |
|
257 | + if (version_compare($curl_version['version'], '7.40', '<')) { |
|
258 | + echo '<mark class="error"><span class="dashicons dashicons-warning"></span> '.sprintf(__('%s - We recommend a minimum cURL version of 7.40.', 'give'), esc_html($curl_version['version'].', '.$curl_version['ssl_version'])).'</mark>'; |
|
259 | 259 | } else { |
260 | - echo '<mark class="yes">' . esc_html( $curl_version['version'] . ', ' . $curl_version['ssl_version'] ) . '</mark>'; |
|
260 | + echo '<mark class="yes">'.esc_html($curl_version['version'].', '.$curl_version['ssl_version']).'</mark>'; |
|
261 | 261 | } |
262 | 262 | } else { |
263 | 263 | echo '&ndash'; |
@@ -266,42 +266,42 @@ discard block |
||
266 | 266 | </td> |
267 | 267 | </tr> |
268 | 268 | <tr> |
269 | - <td data-export-label="SUHOSIN Installed"><?php _e( 'SUHOSIN Installed', 'give' ); ?>:</td> |
|
270 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Suhosin is an advanced protection system for PHP installations. It was designed to protect your servers on the one hand against a number of well known problems in PHP applications and on the other hand against potential unknown vulnerabilities within these applications or the PHP core itself. If enabled on your server, Suhosin may need to be configured to increase its data submission limits.', 'give' ) ); ?></td> |
|
271 | - <td><?php echo extension_loaded( 'suhosin' ) ? '<span class="dashicons dashicons-yes"></span>' : '–'; ?></td> |
|
269 | + <td data-export-label="SUHOSIN Installed"><?php _e('SUHOSIN Installed', 'give'); ?>:</td> |
|
270 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Suhosin is an advanced protection system for PHP installations. It was designed to protect your servers on the one hand against a number of well known problems in PHP applications and on the other hand against potential unknown vulnerabilities within these applications or the PHP core itself. If enabled on your server, Suhosin may need to be configured to increase its data submission limits.', 'give')); ?></td> |
|
271 | + <td><?php echo extension_loaded('suhosin') ? '<span class="dashicons dashicons-yes"></span>' : '–'; ?></td> |
|
272 | 272 | </tr> |
273 | 273 | <?php endif; |
274 | 274 | |
275 | - if ( $wpdb->use_mysqli ) { |
|
276 | - $ver = mysqli_get_server_info( $wpdb->dbh ); |
|
275 | + if ($wpdb->use_mysqli) { |
|
276 | + $ver = mysqli_get_server_info($wpdb->dbh); |
|
277 | 277 | } else { |
278 | 278 | $ver = mysql_get_server_info(); |
279 | 279 | } |
280 | 280 | |
281 | - if ( ! empty( $wpdb->is_mysql ) && ! stristr( $ver, 'MariaDB' ) ) : ?> |
|
281 | + if ( ! empty($wpdb->is_mysql) && ! stristr($ver, 'MariaDB')) : ?> |
|
282 | 282 | <tr> |
283 | - <td data-export-label="MySQL Version"><?php _e( 'MySQL Version', 'give' ); ?>:</td> |
|
284 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of MySQL installed on your hosting server.', 'give' ) ); ?></td> |
|
283 | + <td data-export-label="MySQL Version"><?php _e('MySQL Version', 'give'); ?>:</td> |
|
284 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of MySQL installed on your hosting server.', 'give')); ?></td> |
|
285 | 285 | <td> |
286 | 286 | <?php |
287 | 287 | $mysql_version = $wpdb->db_version(); |
288 | 288 | |
289 | - if ( version_compare( $mysql_version, '5.6', '<' ) ) { |
|
290 | - echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( '%s - We recommend a minimum MySQL version of 5.6. See: %s', 'give' ), esc_html( $mysql_version ), '<a href="https://wordpress.org/about/requirements/" target="_blank">' . __( 'WordPress Requirements', 'give' ) . '</a>' ) . '</mark>'; |
|
289 | + if (version_compare($mysql_version, '5.6', '<')) { |
|
290 | + echo '<mark class="error"><span class="dashicons dashicons-warning"></span> '.sprintf(__('%s - We recommend a minimum MySQL version of 5.6. See: %s', 'give'), esc_html($mysql_version), '<a href="https://wordpress.org/about/requirements/" target="_blank">'.__('WordPress Requirements', 'give').'</a>').'</mark>'; |
|
291 | 291 | } else { |
292 | - echo '<mark class="yes">' . esc_html( $mysql_version ) . '</mark>'; |
|
292 | + echo '<mark class="yes">'.esc_html($mysql_version).'</mark>'; |
|
293 | 293 | } |
294 | 294 | ?> |
295 | 295 | </td> |
296 | 296 | </tr> |
297 | 297 | <?php endif; ?> |
298 | 298 | <tr> |
299 | - <td data-export-label="Default Timezone is UTC"><?php _e( 'Default Timezone is UTC', 'give' ); ?>:</td> |
|
300 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The default timezone for your server.', 'give' ) ); ?></td> |
|
299 | + <td data-export-label="Default Timezone is UTC"><?php _e('Default Timezone is UTC', 'give'); ?>:</td> |
|
300 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The default timezone for your server.', 'give')); ?></td> |
|
301 | 301 | <td><?php |
302 | 302 | $default_timezone = date_default_timezone_get(); |
303 | - if ( 'UTC' !== $default_timezone ) { |
|
304 | - echo '<mark class="error"><span class="dashicons dashicons-warning"></span> ' . sprintf( __( 'Default timezone is %s - it should be UTC', 'give' ), $default_timezone ) . '</mark>'; |
|
303 | + if ('UTC' !== $default_timezone) { |
|
304 | + echo '<mark class="error"><span class="dashicons dashicons-warning"></span> '.sprintf(__('Default timezone is %s - it should be UTC', 'give'), $default_timezone).'</mark>'; |
|
305 | 305 | } else { |
306 | 306 | echo '<mark class="yes"><span class="dashicons dashicons-yes"></span></mark>'; |
307 | 307 | } ?> |
@@ -312,119 +312,119 @@ discard block |
||
312 | 312 | |
313 | 313 | // fsockopen/cURL. |
314 | 314 | $posting['fsockopen_curl']['name'] = 'fsockopen/cURL'; |
315 | - $posting['fsockopen_curl']['help'] = __( 'Payment gateways can use cURL to communicate with remote servers to authorize payments, other plugins may also use it when communicating with remote services.', 'give' ); |
|
315 | + $posting['fsockopen_curl']['help'] = __('Payment gateways can use cURL to communicate with remote servers to authorize payments, other plugins may also use it when communicating with remote services.', 'give'); |
|
316 | 316 | |
317 | - if ( function_exists( 'fsockopen' ) || function_exists( 'curl_init' ) ) { |
|
317 | + if (function_exists('fsockopen') || function_exists('curl_init')) { |
|
318 | 318 | $posting['fsockopen_curl']['success'] = true; |
319 | 319 | } else { |
320 | 320 | $posting['fsockopen_curl']['success'] = false; |
321 | - $posting['fsockopen_curl']['note'] = __( 'Your server does not have fsockopen or cURL enabled - PayPal IPN and other scripts which communicate with other servers will not work. Contact your hosting provider.', 'give' ); |
|
321 | + $posting['fsockopen_curl']['note'] = __('Your server does not have fsockopen or cURL enabled - PayPal IPN and other scripts which communicate with other servers will not work. Contact your hosting provider.', 'give'); |
|
322 | 322 | } |
323 | 323 | |
324 | 324 | // SOAP. |
325 | 325 | $posting['soap_client']['name'] = 'SoapClient'; |
326 | - $posting['soap_client']['help'] = __( 'Some webservices like shipping use SOAP to get information from remote servers, for example, live shipping quotes from FedEx require SOAP to be installed.', 'give' ); |
|
326 | + $posting['soap_client']['help'] = __('Some webservices like shipping use SOAP to get information from remote servers, for example, live shipping quotes from FedEx require SOAP to be installed.', 'give'); |
|
327 | 327 | |
328 | - if ( class_exists( 'SoapClient' ) ) { |
|
328 | + if (class_exists('SoapClient')) { |
|
329 | 329 | $posting['soap_client']['success'] = true; |
330 | 330 | } else { |
331 | 331 | $posting['soap_client']['success'] = false; |
332 | - $posting['soap_client']['note'] = sprintf( __( 'Your server does not have the %s class enabled - some gateway plugins which use SOAP may not work as expected.', 'give' ), '<a href="https://php.net/manual/en/class.soapclient.php">SoapClient</a>' ); |
|
332 | + $posting['soap_client']['note'] = sprintf(__('Your server does not have the %s class enabled - some gateway plugins which use SOAP may not work as expected.', 'give'), '<a href="https://php.net/manual/en/class.soapclient.php">SoapClient</a>'); |
|
333 | 333 | } |
334 | 334 | |
335 | 335 | // DOMDocument. |
336 | 336 | $posting['dom_document']['name'] = 'DOMDocument'; |
337 | - $posting['dom_document']['help'] = __( 'HTML/Multipart emails use DOMDocument to generate inline CSS in templates.', 'give' ); |
|
337 | + $posting['dom_document']['help'] = __('HTML/Multipart emails use DOMDocument to generate inline CSS in templates.', 'give'); |
|
338 | 338 | |
339 | - if ( class_exists( 'DOMDocument' ) ) { |
|
339 | + if (class_exists('DOMDocument')) { |
|
340 | 340 | $posting['dom_document']['success'] = true; |
341 | 341 | } else { |
342 | 342 | $posting['dom_document']['success'] = false; |
343 | - $posting['dom_document']['note'] = sprintf( __( 'Your server does not have the %s class enabled - HTML/Multipart emails, and also some extensions, will not work without DOMDocument.', 'give' ), '<a href="https://php.net/manual/en/class.domdocument.php">DOMDocument</a>' ); |
|
343 | + $posting['dom_document']['note'] = sprintf(__('Your server does not have the %s class enabled - HTML/Multipart emails, and also some extensions, will not work without DOMDocument.', 'give'), '<a href="https://php.net/manual/en/class.domdocument.php">DOMDocument</a>'); |
|
344 | 344 | } |
345 | 345 | |
346 | 346 | // gzip. |
347 | 347 | $posting['gzip']['name'] = 'gzip'; |
348 | - $posting['gzip']['help'] = __( 'gzip is used for file compression and decompression.', 'give' ); |
|
348 | + $posting['gzip']['help'] = __('gzip is used for file compression and decompression.', 'give'); |
|
349 | 349 | |
350 | - if ( is_callable( 'gzopen' ) ) { |
|
350 | + if (is_callable('gzopen')) { |
|
351 | 351 | $posting['gzip']['success'] = true; |
352 | 352 | } else { |
353 | 353 | $posting['gzip']['success'] = false; |
354 | - $posting['gzip']['note'] = sprintf( __( 'Your server does not support the %s function - this is used for file compression and decompression.', 'give' ), '<a href="https://php.net/manual/en/zlib.installation.php">gzopen</a>' ); |
|
354 | + $posting['gzip']['note'] = sprintf(__('Your server does not support the %s function - this is used for file compression and decompression.', 'give'), '<a href="https://php.net/manual/en/zlib.installation.php">gzopen</a>'); |
|
355 | 355 | } |
356 | 356 | |
357 | 357 | |
358 | 358 | // GD Graphics Library. |
359 | 359 | $posting['gd']['name'] = 'GD Graphics Library'; |
360 | - $posting['gd']['help'] = __( 'GD Graphics Library is used for dynamically manipulating images.', 'give' ); |
|
361 | - $posting['gd']['success'] = extension_loaded( 'gd' ) && function_exists( 'gd_info' ) ? true : false; |
|
360 | + $posting['gd']['help'] = __('GD Graphics Library is used for dynamically manipulating images.', 'give'); |
|
361 | + $posting['gd']['success'] = extension_loaded('gd') && function_exists('gd_info') ? true : false; |
|
362 | 362 | |
363 | 363 | // Multibyte String. |
364 | 364 | $posting['mbstring']['name'] = 'Multibyte String'; |
365 | - $posting['mbstring']['help'] = __( 'Multibyte String (mbstring) is used to convert character encoding, like for emails or converting characters to lowercase.', 'give' ); |
|
365 | + $posting['mbstring']['help'] = __('Multibyte String (mbstring) is used to convert character encoding, like for emails or converting characters to lowercase.', 'give'); |
|
366 | 366 | |
367 | - if ( extension_loaded( 'mbstring' ) ) { |
|
367 | + if (extension_loaded('mbstring')) { |
|
368 | 368 | $posting['mbstring']['success'] = true; |
369 | 369 | } else { |
370 | 370 | $posting['mbstring']['success'] = false; |
371 | - $posting['mbstring']['note'] = sprintf( __( 'Your server does not support the %s functions - this is required for better character encoding. Some fallbacks will be used instead for it.', 'give' ), '<a href="https://php.net/manual/en/mbstring.installation.php">mbstring</a>' ); |
|
371 | + $posting['mbstring']['note'] = sprintf(__('Your server does not support the %s functions - this is required for better character encoding. Some fallbacks will be used instead for it.', 'give'), '<a href="https://php.net/manual/en/mbstring.installation.php">mbstring</a>'); |
|
372 | 372 | } |
373 | 373 | |
374 | 374 | // WP Remote Post Check. |
375 | - $posting['wp_remote_post']['name'] = __( 'Remote Post', 'give' ); |
|
376 | - $posting['wp_remote_post']['help'] = __( 'PayPal uses this method of communicating when sending back transaction information.', 'give' ); |
|
375 | + $posting['wp_remote_post']['name'] = __('Remote Post', 'give'); |
|
376 | + $posting['wp_remote_post']['help'] = __('PayPal uses this method of communicating when sending back transaction information.', 'give'); |
|
377 | 377 | |
378 | - $response = wp_safe_remote_post( 'https://www.paypal.com/cgi-bin/webscr', array( |
|
378 | + $response = wp_safe_remote_post('https://www.paypal.com/cgi-bin/webscr', array( |
|
379 | 379 | 'timeout' => 60, |
380 | - 'user-agent' => 'Give/' . GIVE_VERSION, |
|
380 | + 'user-agent' => 'Give/'.GIVE_VERSION, |
|
381 | 381 | 'httpversion' => '1.1', |
382 | 382 | 'body' => array( |
383 | 383 | 'cmd' => '_notify-validate', |
384 | 384 | ), |
385 | - ) ); |
|
385 | + )); |
|
386 | 386 | |
387 | - if ( ! is_wp_error( $response ) && $response['response']['code'] >= 200 && $response['response']['code'] < 300 ) { |
|
387 | + if ( ! is_wp_error($response) && $response['response']['code'] >= 200 && $response['response']['code'] < 300) { |
|
388 | 388 | $posting['wp_remote_post']['success'] = true; |
389 | 389 | } else { |
390 | - $posting['wp_remote_post']['note'] = __( 'wp_remote_post() failed. PayPal IPN won\'t work with your server. Contact your hosting provider.', 'give' ); |
|
391 | - if ( is_wp_error( $response ) ) { |
|
392 | - $posting['wp_remote_post']['note'] .= ' ' . sprintf( __( 'Error: %s', 'give' ), sanitize_text_field( $response->get_error_message() ) ); |
|
390 | + $posting['wp_remote_post']['note'] = __('wp_remote_post() failed. PayPal IPN won\'t work with your server. Contact your hosting provider.', 'give'); |
|
391 | + if (is_wp_error($response)) { |
|
392 | + $posting['wp_remote_post']['note'] .= ' '.sprintf(__('Error: %s', 'give'), sanitize_text_field($response->get_error_message())); |
|
393 | 393 | } else { |
394 | - $posting['wp_remote_post']['note'] .= ' ' . sprintf( __( 'Status code: %s', 'give' ), sanitize_text_field( $response['response']['code'] ) ); |
|
394 | + $posting['wp_remote_post']['note'] .= ' '.sprintf(__('Status code: %s', 'give'), sanitize_text_field($response['response']['code'])); |
|
395 | 395 | } |
396 | 396 | $posting['wp_remote_post']['success'] = false; |
397 | 397 | } |
398 | 398 | |
399 | 399 | // WP Remote Get Check. |
400 | - $posting['wp_remote_get']['name'] = __( 'Remote Get', 'give' ); |
|
401 | - $posting['wp_remote_get']['help'] = __( 'Give plugins may use this method of communication when checking for plugin updates.', 'give' ); |
|
400 | + $posting['wp_remote_get']['name'] = __('Remote Get', 'give'); |
|
401 | + $posting['wp_remote_get']['help'] = __('Give plugins may use this method of communication when checking for plugin updates.', 'give'); |
|
402 | 402 | |
403 | - $response = wp_safe_remote_get( 'https://woocommerce.com/wc-api/product-key-api?request=ping&network=' . ( is_multisite() ? '1' : '0' ) ); |
|
403 | + $response = wp_safe_remote_get('https://woocommerce.com/wc-api/product-key-api?request=ping&network='.(is_multisite() ? '1' : '0')); |
|
404 | 404 | |
405 | - if ( ! is_wp_error( $response ) && $response['response']['code'] >= 200 && $response['response']['code'] < 300 ) { |
|
405 | + if ( ! is_wp_error($response) && $response['response']['code'] >= 200 && $response['response']['code'] < 300) { |
|
406 | 406 | $posting['wp_remote_get']['success'] = true; |
407 | 407 | } else { |
408 | - $posting['wp_remote_get']['note'] = __( 'wp_remote_get() failed. The Give plugin updater won\'t work with your server. Contact your hosting provider.', 'give' ); |
|
409 | - if ( is_wp_error( $response ) ) { |
|
410 | - $posting['wp_remote_get']['note'] .= ' ' . sprintf( __( 'Error: %s', 'give' ), give_clean( $response->get_error_message() ) ); |
|
408 | + $posting['wp_remote_get']['note'] = __('wp_remote_get() failed. The Give plugin updater won\'t work with your server. Contact your hosting provider.', 'give'); |
|
409 | + if (is_wp_error($response)) { |
|
410 | + $posting['wp_remote_get']['note'] .= ' '.sprintf(__('Error: %s', 'give'), give_clean($response->get_error_message())); |
|
411 | 411 | } else { |
412 | - $posting['wp_remote_get']['note'] .= ' ' . sprintf( __( 'Status code: %s', 'give' ), give_clean( $response['response']['code'] ) ); |
|
412 | + $posting['wp_remote_get']['note'] .= ' '.sprintf(__('Status code: %s', 'give'), give_clean($response['response']['code'])); |
|
413 | 413 | } |
414 | 414 | $posting['wp_remote_get']['success'] = false; |
415 | 415 | } |
416 | 416 | |
417 | - $posting = apply_filters( 'give_debug_posting', $posting ); |
|
417 | + $posting = apply_filters('give_debug_posting', $posting); |
|
418 | 418 | |
419 | - foreach ( $posting as $post ) { |
|
420 | - $mark = ! empty( $post['success'] ) ? 'yes' : 'error'; |
|
419 | + foreach ($posting as $post) { |
|
420 | + $mark = ! empty($post['success']) ? 'yes' : 'error'; |
|
421 | 421 | ?> |
422 | 422 | <tr> |
423 | - <td data-export-label="<?php echo esc_html( $post['name'] ); ?>"><?php echo esc_html( $post['name'] ); ?>:</td> |
|
424 | - <td class="help"><?php echo Give()->tooltips->render_help( esc_attr( isset( $post['help'] ) ? $post['help'] : '' ) ); ?></td> |
|
423 | + <td data-export-label="<?php echo esc_html($post['name']); ?>"><?php echo esc_html($post['name']); ?>:</td> |
|
424 | + <td class="help"><?php echo Give()->tooltips->render_help(esc_attr(isset($post['help']) ? $post['help'] : '')); ?></td> |
|
425 | 425 | <td> |
426 | 426 | <mark class="<?php echo $mark; ?>"> |
427 | - <?php echo ! empty( $post['success'] ) ? '<span class="dashicons dashicons-yes"></span>' : '<span class="dashicons dashicons-no-alt"></span>'; ?> <?php echo ! empty( $post['note'] ) ? wp_kses_data( $post['note'] ) : ''; ?> |
|
427 | + <?php echo ! empty($post['success']) ? '<span class="dashicons dashicons-yes"></span>' : '<span class="dashicons dashicons-no-alt"></span>'; ?> <?php echo ! empty($post['note']) ? wp_kses_data($post['note']) : ''; ?> |
|
428 | 428 | </mark> |
429 | 429 | </td> |
430 | 430 | </tr> |
@@ -437,41 +437,41 @@ discard block |
||
437 | 437 | <table class="give-status-table widefat" cellspacing="0"> |
438 | 438 | <thead> |
439 | 439 | <tr> |
440 | - <th colspan="3" data-export-label="Give Configuration"><h2><?php _e( 'Give Configuration', 'give' ); ?></h2></th> |
|
440 | + <th colspan="3" data-export-label="Give Configuration"><h2><?php _e('Give Configuration', 'give'); ?></h2></th> |
|
441 | 441 | </tr> |
442 | 442 | </thead> |
443 | 443 | <tbody> |
444 | 444 | <tr> |
445 | - <td data-export-label="Give Version"><?php _e( 'Give Version', 'give' ); ?>:</td> |
|
446 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of Give installed on your site.', 'give' ) ); ?></td> |
|
447 | - <td><?php echo esc_html( GIVE_VERSION ); ?></td> |
|
445 | + <td data-export-label="Give Version"><?php _e('Give Version', 'give'); ?>:</td> |
|
446 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of Give installed on your site.', 'give')); ?></td> |
|
447 | + <td><?php echo esc_html(GIVE_VERSION); ?></td> |
|
448 | 448 | </tr> |
449 | 449 | <tr> |
450 | - <td data-export-label="Give Cache"><?php _e( 'Give Cache', 'give' ); ?>:</td> |
|
451 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether cache is enabled in Give settings.', 'give' ) ); ?></td> |
|
452 | - <td><?php echo give_is_setting_enabled( give_get_option('cache', 'enabled' ) ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
450 | + <td data-export-label="Give Cache"><?php _e('Give Cache', 'give'); ?>:</td> |
|
451 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether cache is enabled in Give settings.', 'give')); ?></td> |
|
452 | + <td><?php echo give_is_setting_enabled(give_get_option('cache', 'enabled')) ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
453 | 453 | </tr> |
454 | 454 | <tr> |
455 | - <td data-export-label="Database Updates"><?php _e( 'Database Updates', 'give' ); ?>:</td> |
|
456 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'This will show the number of pending database updates.', 'give' ) ); ?></td> |
|
455 | + <td data-export-label="Database Updates"><?php _e('Database Updates', 'give'); ?>:</td> |
|
456 | + <td class="help"><?php echo Give()->tooltips->render_help(__('This will show the number of pending database updates.', 'give')); ?></td> |
|
457 | 457 | <td> |
458 | 458 | <?php |
459 | - $updates_text = __( 'All DB Updates Completed.', 'give' ); |
|
459 | + $updates_text = __('All DB Updates Completed.', 'give'); |
|
460 | 460 | $pending_updates = $give_updates->get_total_new_db_update_count(); |
461 | 461 | $total_updates = $give_updates->get_total_db_update_count(); |
462 | 462 | |
463 | - if( $pending_updates === $total_updates ) { |
|
463 | + if ($pending_updates === $total_updates) { |
|
464 | 464 | |
465 | 465 | // When all the db updates are pending. |
466 | 466 | $updates_text = sprintf( |
467 | - __( '%1$s updates still need to run.', 'give' ), |
|
467 | + __('%1$s updates still need to run.', 'give'), |
|
468 | 468 | $total_updates |
469 | 469 | ); |
470 | - } elseif( $pending_updates > 0 ) { |
|
470 | + } elseif ($pending_updates > 0) { |
|
471 | 471 | |
472 | 472 | // When some of the db updates are completed and some are pending. |
473 | 473 | $updates_text = sprintf( |
474 | - __( '%1$s of %2$s updates still need to run.', 'give' ), |
|
474 | + __('%1$s of %2$s updates still need to run.', 'give'), |
|
475 | 475 | $pending_updates, |
476 | 476 | $total_updates |
477 | 477 | ); |
@@ -482,144 +482,143 @@ discard block |
||
482 | 482 | </td> |
483 | 483 | </tr> |
484 | 484 | <tr> |
485 | - <td data-export-label="Give Cache"><?php _e( 'Give Cache', 'give' ); ?>:</td> |
|
486 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether cache is enabled in Give settings.', 'give' ) ); ?></td> |
|
487 | - <td><?php echo give_is_setting_enabled( give_get_option('cache', 'enabled' ) ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
485 | + <td data-export-label="Give Cache"><?php _e('Give Cache', 'give'); ?>:</td> |
|
486 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether cache is enabled in Give settings.', 'give')); ?></td> |
|
487 | + <td><?php echo give_is_setting_enabled(give_get_option('cache', 'enabled')) ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
488 | 488 | </tr> |
489 | 489 | <tr> |
490 | - <td data-export-label="Give Cache"><?php _e( 'Give Emails', 'give' ); ?>:</td> |
|
491 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether emails is enabled in Give settings.', 'give' ) ); ?></td> |
|
490 | + <td data-export-label="Give Cache"><?php _e('Give Emails', 'give'); ?>:</td> |
|
491 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether emails is enabled in Give settings.', 'give')); ?></td> |
|
492 | 492 | <td> |
493 | 493 | <?php |
494 | 494 | /* @var Give_Email_Notification $email_notification */ |
495 | - if( $email_notifications = Give_Email_Notifications::get_instance()->get_email_notifications() ) { |
|
495 | + if ($email_notifications = Give_Email_Notifications::get_instance()->get_email_notifications()) { |
|
496 | 496 | ob_start(); |
497 | 497 | |
498 | - foreach ( Give_Email_Notifications::get_instance()->get_email_notifications() as $email_notification ) { |
|
499 | - $status = Give_Email_Notification_Util::is_email_notification_active( $email_notification ) ? |
|
500 | - 'yes' : |
|
501 | - 'error'; |
|
498 | + foreach (Give_Email_Notifications::get_instance()->get_email_notifications() as $email_notification) { |
|
499 | + $status = Give_Email_Notification_Util::is_email_notification_active($email_notification) ? |
|
500 | + 'yes' : 'error'; |
|
502 | 501 | |
503 | 502 | echo sprintf( |
504 | 503 | '<li><mark class="%1$s"><span class="dashicons dashicons-%2$s"></mark></span>%3$s</li>', |
505 | - Give_Email_Notification_Util::is_email_notification_active( $email_notification ) ? 'yes' : 'error', |
|
506 | - Give_Email_Notification_Util::is_email_notification_active( $email_notification ) ? 'yes' : 'no-alt', |
|
504 | + Give_Email_Notification_Util::is_email_notification_active($email_notification) ? 'yes' : 'error', |
|
505 | + Give_Email_Notification_Util::is_email_notification_active($email_notification) ? 'yes' : 'no-alt', |
|
507 | 506 | $email_notification->config['label'] |
508 | 507 | ); |
509 | 508 | } |
510 | 509 | |
511 | - echo sprintf( '<ul>%s</ul>', ob_get_clean() ); |
|
510 | + echo sprintf('<ul>%s</ul>', ob_get_clean()); |
|
512 | 511 | } |
513 | 512 | ?> |
514 | 513 | </td> |
515 | 514 | </tr> |
516 | 515 | <tr> |
517 | - <td data-export-label="Upgraded From"><?php _e( 'Upgraded From', 'give' ); ?>:</td> |
|
518 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The version of Give installed prior to the last update.', 'give' ) ); ?></td> |
|
519 | - <td><?php echo esc_html( get_option( 'give_version_upgraded_from', '–' ) ); ?></td> |
|
516 | + <td data-export-label="Upgraded From"><?php _e('Upgraded From', 'give'); ?>:</td> |
|
517 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The version of Give installed prior to the last update.', 'give')); ?></td> |
|
518 | + <td><?php echo esc_html(get_option('give_version_upgraded_from', '–')); ?></td> |
|
520 | 519 | </tr> |
521 | 520 | <tr> |
522 | - <td data-export-label="Test Mode"><?php _e( 'Test Mode', 'give' ); ?>:</td> |
|
523 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether Test Mode is enabled in Give settings.', 'give' ) ); ?></td> |
|
524 | - <td><?php echo give_is_test_mode() ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
521 | + <td data-export-label="Test Mode"><?php _e('Test Mode', 'give'); ?>:</td> |
|
522 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether Test Mode is enabled in Give settings.', 'give')); ?></td> |
|
523 | + <td><?php echo give_is_test_mode() ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
525 | 524 | </tr> |
526 | 525 | <tr> |
527 | - <td data-export-label="Currency Code"><?php _e( 'Currency Code', 'give' ); ?>:</td> |
|
528 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The currency code selected in Give settings.', 'give' ) ); ?></td> |
|
529 | - <td><?php echo esc_html( give_get_currency() ); ?></td> |
|
526 | + <td data-export-label="Currency Code"><?php _e('Currency Code', 'give'); ?>:</td> |
|
527 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The currency code selected in Give settings.', 'give')); ?></td> |
|
528 | + <td><?php echo esc_html(give_get_currency()); ?></td> |
|
530 | 529 | </tr> |
531 | 530 | <tr> |
532 | - <td data-export-label="Currency Position"><?php _e( 'Currency Position', 'give' ); ?>:</td> |
|
533 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The currency position selected in Give settings.', 'give' ) ); ?></td> |
|
534 | - <td><?php echo 'before' === give_get_option( 'currency_position' ) ? __( 'Before', 'give' ) : __( 'After', 'give' ); ?></td> |
|
531 | + <td data-export-label="Currency Position"><?php _e('Currency Position', 'give'); ?>:</td> |
|
532 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The currency position selected in Give settings.', 'give')); ?></td> |
|
533 | + <td><?php echo 'before' === give_get_option('currency_position') ? __('Before', 'give') : __('After', 'give'); ?></td> |
|
535 | 534 | </tr> |
536 | 535 | <tr> |
537 | - <td data-export-label="Decimal Separator"><?php _e( 'Decimal Separator', 'give' ); ?>:</td> |
|
538 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The decimal separator defined in Give settings.', 'give' ) ); ?></td> |
|
539 | - <td><?php echo esc_html( give_get_price_decimal_separator() ); ?></td> |
|
536 | + <td data-export-label="Decimal Separator"><?php _e('Decimal Separator', 'give'); ?>:</td> |
|
537 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The decimal separator defined in Give settings.', 'give')); ?></td> |
|
538 | + <td><?php echo esc_html(give_get_price_decimal_separator()); ?></td> |
|
540 | 539 | </tr> |
541 | 540 | <tr> |
542 | - <td data-export-label="Thousands Separator"><?php _e( 'Thousands Separator', 'give' ); ?>:</td> |
|
543 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The thousands separator defined in Give settings.', 'give' ) ); ?></td> |
|
544 | - <td><?php echo esc_html( give_get_price_thousand_separator() ); ?></td> |
|
541 | + <td data-export-label="Thousands Separator"><?php _e('Thousands Separator', 'give'); ?>:</td> |
|
542 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The thousands separator defined in Give settings.', 'give')); ?></td> |
|
543 | + <td><?php echo esc_html(give_get_price_thousand_separator()); ?></td> |
|
545 | 544 | </tr> |
546 | 545 | <tr> |
547 | - <td data-export-label="Success Page"><?php _e( 'Success Page', 'give' ); ?>:</td> |
|
548 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The page where donors land following a successful transaction.', 'give' ) ); ?></td> |
|
549 | - <td><?php echo ! empty( $give_options['success_page'] ) ? esc_url( get_permalink( $give_options['success_page'] ) ) : '–'; ?></td> |
|
546 | + <td data-export-label="Success Page"><?php _e('Success Page', 'give'); ?>:</td> |
|
547 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The page where donors land following a successful transaction.', 'give')); ?></td> |
|
548 | + <td><?php echo ! empty($give_options['success_page']) ? esc_url(get_permalink($give_options['success_page'])) : '–'; ?></td> |
|
550 | 549 | </tr> |
551 | 550 | <tr> |
552 | - <td data-export-label="Failure Page"><?php _e( 'Failure Page', 'give' ); ?>:</td> |
|
553 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The page where donors land following a failed transaction.', 'give' ) ); ?></td> |
|
554 | - <td><?php echo ! empty( $give_options['failure_page'] ) ? esc_url( get_permalink( $give_options['failure_page'] ) ) : '–'; ?></td> |
|
551 | + <td data-export-label="Failure Page"><?php _e('Failure Page', 'give'); ?>:</td> |
|
552 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The page where donors land following a failed transaction.', 'give')); ?></td> |
|
553 | + <td><?php echo ! empty($give_options['failure_page']) ? esc_url(get_permalink($give_options['failure_page'])) : '–'; ?></td> |
|
555 | 554 | </tr> |
556 | 555 | <tr> |
557 | - <td data-export-label="Donation History Page"><?php _e( 'Donation History Page', 'give' ); ?>:</td> |
|
558 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The page where past donations are listed.', 'give' ) ); ?></td> |
|
559 | - <td><?php echo ! empty( $give_options['history_page'] ) ? esc_url( get_permalink( $give_options['history_page'] ) ) : '–'; ?></td> |
|
556 | + <td data-export-label="Donation History Page"><?php _e('Donation History Page', 'give'); ?>:</td> |
|
557 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The page where past donations are listed.', 'give')); ?></td> |
|
558 | + <td><?php echo ! empty($give_options['history_page']) ? esc_url(get_permalink($give_options['history_page'])) : '–'; ?></td> |
|
560 | 559 | </tr> |
561 | 560 | <tr> |
562 | - <td data-export-label="Give Forms Slug"><?php _e( 'Give Forms Slug', 'give' ); ?>:</td> |
|
563 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The slug used for Give donation forms.', 'give' ) ); ?></td> |
|
564 | - <td><?php echo esc_html( defined( 'GIVE_SLUG' ) ? '/' . GIVE_SLUG . '/' : '/donations/' ); ?></td> |
|
561 | + <td data-export-label="Give Forms Slug"><?php _e('Give Forms Slug', 'give'); ?>:</td> |
|
562 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The slug used for Give donation forms.', 'give')); ?></td> |
|
563 | + <td><?php echo esc_html(defined('GIVE_SLUG') ? '/'.GIVE_SLUG.'/' : '/donations/'); ?></td> |
|
565 | 564 | </tr> |
566 | 565 | <?php |
567 | 566 | $active_gateways = give_get_enabled_payment_gateways(); |
568 | 567 | $enabled_gateways = $default_gateway = ''; |
569 | 568 | |
570 | - if ( $active_gateways ) { |
|
571 | - $default_gateway_is_active = give_is_gateway_active( give_get_default_gateway( null ) ); |
|
569 | + if ($active_gateways) { |
|
570 | + $default_gateway_is_active = give_is_gateway_active(give_get_default_gateway(null)); |
|
572 | 571 | |
573 | - if ( $default_gateway_is_active ) { |
|
574 | - $default_gateway = give_get_default_gateway( null ); |
|
575 | - $default_gateway = $active_gateways[ $default_gateway ]['admin_label']; |
|
572 | + if ($default_gateway_is_active) { |
|
573 | + $default_gateway = give_get_default_gateway(null); |
|
574 | + $default_gateway = $active_gateways[$default_gateway]['admin_label']; |
|
576 | 575 | } else { |
577 | - $default_gateway = __( 'Test Donation', 'give' ); |
|
576 | + $default_gateway = __('Test Donation', 'give'); |
|
578 | 577 | } |
579 | 578 | |
580 | 579 | $gateways = array(); |
581 | 580 | |
582 | - foreach ( $active_gateways as $gateway ) { |
|
581 | + foreach ($active_gateways as $gateway) { |
|
583 | 582 | $gateways[] = $gateway['admin_label']; |
584 | 583 | } |
585 | 584 | |
586 | - $enabled_gateways = implode( ', ', $gateways ); |
|
585 | + $enabled_gateways = implode(', ', $gateways); |
|
587 | 586 | } |
588 | 587 | ?> |
589 | 588 | <tr> |
590 | - <td data-export-label="Enabled Payment Gateways"><?php _e( 'Enabled Payment Gateways', 'give' ); ?>:</td> |
|
591 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'All payment gateways enabled in Give settings.', 'give' ) ); ?></td> |
|
592 | - <td><?php echo esc_html( ! empty( $enabled_gateways ) ? $enabled_gateways : '–' ); ?></td> |
|
589 | + <td data-export-label="Enabled Payment Gateways"><?php _e('Enabled Payment Gateways', 'give'); ?>:</td> |
|
590 | + <td class="help"><?php echo Give()->tooltips->render_help(__('All payment gateways enabled in Give settings.', 'give')); ?></td> |
|
591 | + <td><?php echo esc_html( ! empty($enabled_gateways) ? $enabled_gateways : '–'); ?></td> |
|
593 | 592 | </tr> |
594 | 593 | <tr> |
595 | - <td data-export-label="Default Payment Gateway"><?php _e( 'Default Payment Gateway', 'give' ); ?>:</td> |
|
596 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The default payment gateway selected in Give settings.', 'give' ) ); ?></td> |
|
597 | - <td><?php echo esc_html( ! empty( $default_gateway ) ? $default_gateway : '–' ); ?></td> |
|
594 | + <td data-export-label="Default Payment Gateway"><?php _e('Default Payment Gateway', 'give'); ?>:</td> |
|
595 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The default payment gateway selected in Give settings.', 'give')); ?></td> |
|
596 | + <td><?php echo esc_html( ! empty($default_gateway) ? $default_gateway : '–'); ?></td> |
|
598 | 597 | </tr> |
599 | 598 | <tr> |
600 | - <td data-export-label="PayPal IPN Verification"><?php _e( 'PayPal IPN Verification', 'give' ); ?>:</td> |
|
601 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether admins requires verification of IPN notifications with PayPal.', 'give' ) ); ?></td> |
|
602 | - <td><?php echo 'enabled' === give_get_option( 'paypal_verification' ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
599 | + <td data-export-label="PayPal IPN Verification"><?php _e('PayPal IPN Verification', 'give'); ?>:</td> |
|
600 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether admins requires verification of IPN notifications with PayPal.', 'give')); ?></td> |
|
601 | + <td><?php echo 'enabled' === give_get_option('paypal_verification') ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
603 | 602 | </tr> |
604 | 603 | <tr> |
605 | - <td data-export-label="PayPal IPN Notifications"><?php _e( 'PayPal IPN Notifications', 'give' ); ?>:</td> |
|
606 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Displays whether when last PayPal IPN is received with which donation or transaction.', 'give' ) ); ?></td> |
|
604 | + <td data-export-label="PayPal IPN Notifications"><?php _e('PayPal IPN Notifications', 'give'); ?>:</td> |
|
605 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Displays whether when last PayPal IPN is received with which donation or transaction.', 'give')); ?></td> |
|
607 | 606 | <td> |
608 | 607 | <?php |
609 | - $last_paypal_ipn_received = get_option( 'give_last_paypal_ipn_received' ); |
|
610 | - if ( is_array( $last_paypal_ipn_received ) && count( $last_paypal_ipn_received ) > 0 ) { |
|
608 | + $last_paypal_ipn_received = get_option('give_last_paypal_ipn_received'); |
|
609 | + if (is_array($last_paypal_ipn_received) && count($last_paypal_ipn_received) > 0) { |
|
611 | 610 | $donation_id = $last_paypal_ipn_received['payment_id']; |
612 | - $ipn_timestamp = give_get_meta( $donation_id, 'give_last_paypal_ipn_received', true ); |
|
613 | - $transaction_url = 'https://history.paypal.com/cgi-bin/webscr?cmd=_history-details-from-hub&id=' . $last_paypal_ipn_received['transaction_id']; |
|
614 | - $donation_url = site_url() . '/wp-admin/edit.php?post_type=give_forms&page=give-payment-history&view=view-payment-details&id=' . $donation_id; |
|
611 | + $ipn_timestamp = give_get_meta($donation_id, 'give_last_paypal_ipn_received', true); |
|
612 | + $transaction_url = 'https://history.paypal.com/cgi-bin/webscr?cmd=_history-details-from-hub&id='.$last_paypal_ipn_received['transaction_id']; |
|
613 | + $donation_url = site_url().'/wp-admin/edit.php?post_type=give_forms&page=give-payment-history&view=view-payment-details&id='.$donation_id; |
|
615 | 614 | echo sprintf( |
616 | - __( 'IPN received for <a href="%s">#%s</a> ( <a href="%s" target="_blank">%s</a> ) on %s at %s. Status %s', 'give' ), |
|
615 | + __('IPN received for <a href="%s">#%s</a> ( <a href="%s" target="_blank">%s</a> ) on %s at %s. Status %s', 'give'), |
|
617 | 616 | $donation_url, |
618 | 617 | $donation_id, |
619 | 618 | $transaction_url, |
620 | 619 | $last_paypal_ipn_received['transaction_id'], |
621 | - date_i18n( 'm/d/Y', $ipn_timestamp ), |
|
622 | - date_i18n( 'H:i', $ipn_timestamp ), |
|
620 | + date_i18n('m/d/Y', $ipn_timestamp), |
|
621 | + date_i18n('H:i', $ipn_timestamp), |
|
623 | 622 | $last_paypal_ipn_received['auth_status'] |
624 | 623 | ); |
625 | 624 | } else { |
@@ -629,9 +628,9 @@ discard block |
||
629 | 628 | </td> |
630 | 629 | </tr> |
631 | 630 | <tr> |
632 | - <td data-export-label="Donor Email Access"><?php _e( 'Donor Email Access', 'give' ); ?>:</td> |
|
633 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether donors can access their donation history using only email.', 'give' ) ); ?></td> |
|
634 | - <td><?php echo 'enabled' === give_get_option( 'email_access' ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
631 | + <td data-export-label="Donor Email Access"><?php _e('Donor Email Access', 'give'); ?>:</td> |
|
632 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether donors can access their donation history using only email.', 'give')); ?></td> |
|
633 | + <td><?php echo 'enabled' === give_get_option('email_access') ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
635 | 634 | </tr> |
636 | 635 | </tbody> |
637 | 636 | </table> |
@@ -639,45 +638,45 @@ discard block |
||
639 | 638 | <table class="give-status-table widefat" cellspacing="0"> |
640 | 639 | <thead> |
641 | 640 | <tr> |
642 | - <th colspan="3" data-export-label="Session Configuration"><h2><?php _e( 'Session Configuration', 'give' ); ?></h2></th> |
|
641 | + <th colspan="3" data-export-label="Session Configuration"><h2><?php _e('Session Configuration', 'give'); ?></h2></th> |
|
643 | 642 | </tr> |
644 | 643 | </thead> |
645 | 644 | <tbody> |
646 | 645 | <tr> |
647 | - <td data-export-label="Give Use Sessions"><?php _e( 'Give Use Sessions', 'give' ); ?>:</td> |
|
648 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether PHP sessions are enforced, enabled, or disabled.', 'give' ) ); ?></td> |
|
649 | - <td><?php echo defined( 'GIVE_USE_PHP_SESSIONS' ) && GIVE_USE_PHP_SESSIONS ? __( 'Enforced', 'give' ) : ( Give()->session->use_php_sessions() ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ) ); ?></td> |
|
646 | + <td data-export-label="Give Use Sessions"><?php _e('Give Use Sessions', 'give'); ?>:</td> |
|
647 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether PHP sessions are enforced, enabled, or disabled.', 'give')); ?></td> |
|
648 | + <td><?php echo defined('GIVE_USE_PHP_SESSIONS') && GIVE_USE_PHP_SESSIONS ? __('Enforced', 'give') : (Give()->session->use_php_sessions() ? __('Enabled', 'give') : __('Disabled', 'give')); ?></td> |
|
650 | 649 | </tr> |
651 | 650 | <tr> |
652 | - <td data-export-label="Session"><?php _e( 'Session', 'give' ); ?>:</td> |
|
653 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether a PHP session is currently set.', 'give' ) ); ?></td> |
|
654 | - <td><?php echo isset( $_SESSION ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
651 | + <td data-export-label="Session"><?php _e('Session', 'give'); ?>:</td> |
|
652 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether a PHP session is currently set.', 'give')); ?></td> |
|
653 | + <td><?php echo isset($_SESSION) ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
655 | 654 | </tr> |
656 | - <?php if ( isset( $_SESSION ) ) { ?> |
|
655 | + <?php if (isset($_SESSION)) { ?> |
|
657 | 656 | <tr> |
658 | - <td data-export-label="Session Name"><?php _e( 'Session Name', 'give' ); ?>:</td> |
|
659 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The name of the current PHP session.', 'give' ) ); ?></td> |
|
660 | - <td><?php echo esc_html( ini_get( 'session.name' ) ); ?></td> |
|
657 | + <td data-export-label="Session Name"><?php _e('Session Name', 'give'); ?>:</td> |
|
658 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The name of the current PHP session.', 'give')); ?></td> |
|
659 | + <td><?php echo esc_html(ini_get('session.name')); ?></td> |
|
661 | 660 | </tr> |
662 | 661 | <tr> |
663 | - <td data-export-label="Cookie Path"><?php _e( 'Cookie Path', 'give' ); ?>:</td> |
|
664 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The cookie path of the current PHP session.', 'give' ) ); ?></td> |
|
665 | - <td><?php echo esc_html( ini_get( 'session.cookie_path' ) ); ?></td> |
|
662 | + <td data-export-label="Cookie Path"><?php _e('Cookie Path', 'give'); ?>:</td> |
|
663 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The cookie path of the current PHP session.', 'give')); ?></td> |
|
664 | + <td><?php echo esc_html(ini_get('session.cookie_path')); ?></td> |
|
666 | 665 | </tr> |
667 | 666 | <tr> |
668 | - <td data-export-label="Save Path"><?php _e( 'Save Path', 'give' ); ?>:</td> |
|
669 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The save path of the current PHP session.', 'give' ) ); ?></td> |
|
670 | - <td><?php echo esc_html( ini_get( 'session.save_path' ) ); ?></td> |
|
667 | + <td data-export-label="Save Path"><?php _e('Save Path', 'give'); ?>:</td> |
|
668 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The save path of the current PHP session.', 'give')); ?></td> |
|
669 | + <td><?php echo esc_html(ini_get('session.save_path')); ?></td> |
|
671 | 670 | </tr> |
672 | 671 | <tr> |
673 | - <td data-export-label="Use Cookies"><?php _e( 'Use Cookies', 'give' ); ?>:</td> |
|
674 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether the current PHP session is set to use cookies.', 'give' ) ); ?></td> |
|
675 | - <td><?php echo ini_get( 'session.use_cookies' ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
672 | + <td data-export-label="Use Cookies"><?php _e('Use Cookies', 'give'); ?>:</td> |
|
673 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether the current PHP session is set to use cookies.', 'give')); ?></td> |
|
674 | + <td><?php echo ini_get('session.use_cookies') ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
676 | 675 | </tr> |
677 | 676 | <tr> |
678 | - <td data-export-label="Use Only Cookies"><?php _e( 'Use Only Cookies', 'give' ); ?>:</td> |
|
679 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether the current PHP session is set to use only cookies.', 'give' ) ); ?></td> |
|
680 | - <td><?php echo ini_get( 'session.use_only_cookies' ) ? __( 'Enabled', 'give' ) : __( 'Disabled', 'give' ); ?></td> |
|
677 | + <td data-export-label="Use Only Cookies"><?php _e('Use Only Cookies', 'give'); ?>:</td> |
|
678 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether the current PHP session is set to use only cookies.', 'give')); ?></td> |
|
679 | + <td><?php echo ini_get('session.use_only_cookies') ? __('Enabled', 'give') : __('Disabled', 'give'); ?></td> |
|
681 | 680 | </tr> |
682 | 681 | <?php } ?> |
683 | 682 | </tbody> |
@@ -686,13 +685,13 @@ discard block |
||
686 | 685 | <table class="give-status-table widefat" cellspacing="0"> |
687 | 686 | <thead> |
688 | 687 | <tr> |
689 | - <th colspan="3" data-export-label="Active Give Add-ons"><h2><?php _e( 'Active Give Add-ons', 'give' ); ?></h2></th> |
|
688 | + <th colspan="3" data-export-label="Active Give Add-ons"><h2><?php _e('Active Give Add-ons', 'give'); ?></h2></th> |
|
690 | 689 | </tr> |
691 | 690 | </thead> |
692 | 691 | <tbody> |
693 | 692 | <?php |
694 | - foreach ( $plugins as $plugin_data ) { |
|
695 | - if ( 'active' != $plugin_data['Status'] || 'add-on' != $plugin_data['Type'] ) { |
|
693 | + foreach ($plugins as $plugin_data) { |
|
694 | + if ('active' != $plugin_data['Status'] || 'add-on' != $plugin_data['Type']) { |
|
696 | 695 | continue; |
697 | 696 | } |
698 | 697 | |
@@ -700,40 +699,40 @@ discard block |
||
700 | 699 | $author_name = $plugin_data['Author']; |
701 | 700 | |
702 | 701 | // Link the plugin name to the plugin URL if available. |
703 | - if ( ! empty( $plugin_data['PluginURI'] ) ) { |
|
702 | + if ( ! empty($plugin_data['PluginURI'])) { |
|
704 | 703 | $plugin_name = sprintf( |
705 | 704 | '<a href="%s" title="%s">%s</a>', |
706 | - esc_url( $plugin_data['PluginURI'] ), |
|
707 | - esc_attr__( 'Visit plugin homepage', 'give' ), |
|
705 | + esc_url($plugin_data['PluginURI']), |
|
706 | + esc_attr__('Visit plugin homepage', 'give'), |
|
708 | 707 | $plugin_name |
709 | 708 | ); |
710 | 709 | } |
711 | 710 | |
712 | 711 | // Link the author name to the author URL if available. |
713 | - if ( ! empty( $plugin_data['AuthorURI'] ) ) { |
|
712 | + if ( ! empty($plugin_data['AuthorURI'])) { |
|
714 | 713 | $author_name = sprintf( |
715 | 714 | '<a href="%s" title="%s">%s</a>', |
716 | - esc_url( $plugin_data['AuthorURI'] ), |
|
717 | - esc_attr__( 'Visit author homepage', 'give' ), |
|
715 | + esc_url($plugin_data['AuthorURI']), |
|
716 | + esc_attr__('Visit author homepage', 'give'), |
|
718 | 717 | $author_name |
719 | 718 | ); |
720 | 719 | } |
721 | 720 | ?> |
722 | 721 | <tr> |
723 | - <td><?php echo wp_kses( $plugin_name, wp_kses_allowed_html( 'post' ) ); ?></td> |
|
722 | + <td><?php echo wp_kses($plugin_name, wp_kses_allowed_html('post')); ?></td> |
|
724 | 723 | <td class="help"> </td> |
725 | 724 | <td> |
726 | 725 | <?php |
727 | - if ( true === $plugin_data['License'] ) { |
|
728 | - echo '<mark class="yes"><span class="dashicons dashicons-yes"></span></mark> ' . __( 'Licensed', 'give' ); |
|
726 | + if (true === $plugin_data['License']) { |
|
727 | + echo '<mark class="yes"><span class="dashicons dashicons-yes"></span></mark> '.__('Licensed', 'give'); |
|
729 | 728 | } else { |
730 | - echo '<mark class="error"><span class="dashicons dashicons-no-alt"></span></mark> ' . __( 'Unlicensed', 'give' ); |
|
729 | + echo '<mark class="error"><span class="dashicons dashicons-no-alt"></span></mark> '.__('Unlicensed', 'give'); |
|
731 | 730 | } |
732 | 731 | |
733 | 732 | echo ' – ' |
734 | - . sprintf( _x( 'by %s', 'by author', 'give' ), wp_kses( $author_name, wp_kses_allowed_html( 'post' ) ) ) |
|
733 | + . sprintf(_x('by %s', 'by author', 'give'), wp_kses($author_name, wp_kses_allowed_html('post'))) |
|
735 | 734 | . ' – ' |
736 | - . esc_html( $plugin_data['Version'] ); |
|
735 | + . esc_html($plugin_data['Version']); |
|
737 | 736 | ?> |
738 | 737 | </td> |
739 | 738 | </tr> |
@@ -746,18 +745,18 @@ discard block |
||
746 | 745 | <table class="give-status-table widefat" cellspacing="0"> |
747 | 746 | <thead> |
748 | 747 | <tr> |
749 | - <th colspan="3" data-export-label="Other Active Plugins"><h2><?php _e( 'Other Active Plugins', 'give' ); ?></h2></th> |
|
748 | + <th colspan="3" data-export-label="Other Active Plugins"><h2><?php _e('Other Active Plugins', 'give'); ?></h2></th> |
|
750 | 749 | </tr> |
751 | 750 | </thead> |
752 | 751 | <tbody> |
753 | 752 | <?php |
754 | - foreach ( $plugins as $plugin_data ) { |
|
755 | - if ( 'active' != $plugin_data['Status'] || 'other' != $plugin_data['Type'] ) { |
|
753 | + foreach ($plugins as $plugin_data) { |
|
754 | + if ('active' != $plugin_data['Status'] || 'other' != $plugin_data['Type']) { |
|
756 | 755 | continue; |
757 | 756 | } |
758 | 757 | |
759 | 758 | // Do not show Give core plugin. |
760 | - if ( 'Give - Donation Plugin' === $plugin_data['Name'] ) { |
|
759 | + if ('Give - Donation Plugin' === $plugin_data['Name']) { |
|
761 | 760 | continue; |
762 | 761 | } |
763 | 762 | |
@@ -765,29 +764,29 @@ discard block |
||
765 | 764 | $author_name = $plugin_data['Author']; |
766 | 765 | |
767 | 766 | // Link the plugin name to the plugin URL if available. |
768 | - if ( ! empty( $plugin_data['PluginURI'] ) ) { |
|
767 | + if ( ! empty($plugin_data['PluginURI'])) { |
|
769 | 768 | $plugin_name = sprintf( |
770 | 769 | '<a href="%s" title="%s">%s</a>', |
771 | - esc_url( $plugin_data['PluginURI'] ), |
|
772 | - esc_attr__( 'Visit plugin homepage', 'give' ), |
|
770 | + esc_url($plugin_data['PluginURI']), |
|
771 | + esc_attr__('Visit plugin homepage', 'give'), |
|
773 | 772 | $plugin_name |
774 | 773 | ); |
775 | 774 | } |
776 | 775 | |
777 | 776 | // Link the author name to the author URL if available. |
778 | - if ( ! empty( $plugin_data['AuthorURI'] ) ) { |
|
777 | + if ( ! empty($plugin_data['AuthorURI'])) { |
|
779 | 778 | $author_name = sprintf( |
780 | 779 | '<a href="%s" title="%s">%s</a>', |
781 | - esc_url( $plugin_data['AuthorURI'] ), |
|
782 | - esc_attr__( 'Visit author homepage', 'give' ), |
|
780 | + esc_url($plugin_data['AuthorURI']), |
|
781 | + esc_attr__('Visit author homepage', 'give'), |
|
783 | 782 | $author_name |
784 | 783 | ); |
785 | 784 | } |
786 | 785 | ?> |
787 | 786 | <tr> |
788 | - <td><?php echo wp_kses( $plugin_name, wp_kses_allowed_html( 'post' ) ); ?></td> |
|
787 | + <td><?php echo wp_kses($plugin_name, wp_kses_allowed_html('post')); ?></td> |
|
789 | 788 | <td class="help"> </td> |
790 | - <td><?php echo sprintf( _x( 'by %s', 'by author', 'give' ), wp_kses( $author_name, wp_kses_allowed_html( 'post' ) ) ) . ' – ' . esc_html( $plugin_data['Version'] ); ?></td> |
|
789 | + <td><?php echo sprintf(_x('by %s', 'by author', 'give'), wp_kses($author_name, wp_kses_allowed_html('post'))).' – '.esc_html($plugin_data['Version']); ?></td> |
|
791 | 790 | </tr> |
792 | 791 | <?php |
793 | 792 | } |
@@ -798,13 +797,13 @@ discard block |
||
798 | 797 | <table class="give-status-table widefat" cellspacing="0"> |
799 | 798 | <thead> |
800 | 799 | <tr> |
801 | - <th colspan="3" data-export-label="Inactive Plugins"><h2><?php _e( 'Inactive Plugins', 'give' ); ?></h2></th> |
|
800 | + <th colspan="3" data-export-label="Inactive Plugins"><h2><?php _e('Inactive Plugins', 'give'); ?></h2></th> |
|
802 | 801 | </tr> |
803 | 802 | </thead> |
804 | 803 | <tbody> |
805 | 804 | <?php |
806 | - foreach ( $plugins as $plugin_data ) { |
|
807 | - if ( 'inactive' != $plugin_data['Status'] ) { |
|
805 | + foreach ($plugins as $plugin_data) { |
|
806 | + if ('inactive' != $plugin_data['Status']) { |
|
808 | 807 | continue; |
809 | 808 | } |
810 | 809 | |
@@ -812,29 +811,29 @@ discard block |
||
812 | 811 | $author_name = $plugin_data['Author']; |
813 | 812 | |
814 | 813 | // Link the plugin name to the plugin URL if available. |
815 | - if ( ! empty( $plugin_data['PluginURI'] ) ) { |
|
814 | + if ( ! empty($plugin_data['PluginURI'])) { |
|
816 | 815 | $plugin_name = sprintf( |
817 | 816 | '<a href="%s" title="%s">%s</a>', |
818 | - esc_url( $plugin_data['PluginURI'] ), |
|
819 | - esc_attr__( 'Visit plugin homepage', 'give' ), |
|
817 | + esc_url($plugin_data['PluginURI']), |
|
818 | + esc_attr__('Visit plugin homepage', 'give'), |
|
820 | 819 | $plugin_name |
821 | 820 | ); |
822 | 821 | } |
823 | 822 | |
824 | 823 | // Link the author name to the author URL if available. |
825 | - if ( ! empty( $plugin_data['AuthorURI'] ) ) { |
|
824 | + if ( ! empty($plugin_data['AuthorURI'])) { |
|
826 | 825 | $author_name = sprintf( |
827 | 826 | '<a href="%s" title="%s">%s</a>', |
828 | - esc_url( $plugin_data['AuthorURI'] ), |
|
829 | - esc_attr__( 'Visit author homepage', 'give' ), |
|
827 | + esc_url($plugin_data['AuthorURI']), |
|
828 | + esc_attr__('Visit author homepage', 'give'), |
|
830 | 829 | $author_name |
831 | 830 | ); |
832 | 831 | } |
833 | 832 | ?> |
834 | 833 | <tr> |
835 | - <td><?php echo wp_kses( $plugin_name, wp_kses_allowed_html( 'post' ) ); ?></td> |
|
834 | + <td><?php echo wp_kses($plugin_name, wp_kses_allowed_html('post')); ?></td> |
|
836 | 835 | <td class="help"> </td> |
837 | - <td><?php echo sprintf( _x( 'by %s', 'by author', 'give' ), wp_kses( $author_name, wp_kses_allowed_html( 'post' ) ) ) . ' – ' . esc_html( $plugin_data['Version'] ); ?></td> |
|
836 | + <td><?php echo sprintf(_x('by %s', 'by author', 'give'), wp_kses($author_name, wp_kses_allowed_html('post'))).' – '.esc_html($plugin_data['Version']); ?></td> |
|
838 | 837 | </tr> |
839 | 838 | <?php |
840 | 839 | } |
@@ -844,38 +843,38 @@ discard block |
||
844 | 843 | |
845 | 844 | <?php |
846 | 845 | $active_mu_plugins = (array) get_mu_plugins(); |
847 | -if ( ! empty( $active_mu_plugins ) ) { |
|
846 | +if ( ! empty($active_mu_plugins)) { |
|
848 | 847 | ?> |
849 | 848 | <table class="give-status-table widefat" cellspacing="0"> |
850 | 849 | <thead> |
851 | 850 | <tr> |
852 | - <th colspan="3" data-export-label="Active MU Plugins"><h2><?php _e( 'Active MU Plugins', 'give' ); ?></h2></th> |
|
851 | + <th colspan="3" data-export-label="Active MU Plugins"><h2><?php _e('Active MU Plugins', 'give'); ?></h2></th> |
|
853 | 852 | </tr> |
854 | 853 | </thead> |
855 | 854 | <tbody> |
856 | 855 | <?php |
857 | 856 | |
858 | - foreach ( $active_mu_plugins as $mu_plugin_data ) { |
|
859 | - if ( ! empty( $mu_plugin_data['Name'] ) ) { |
|
857 | + foreach ($active_mu_plugins as $mu_plugin_data) { |
|
858 | + if ( ! empty($mu_plugin_data['Name'])) { |
|
860 | 859 | // Link the plugin name to the plugin URL if available. |
861 | - $plugin_name = esc_html( $mu_plugin_data['Name'] ); |
|
860 | + $plugin_name = esc_html($mu_plugin_data['Name']); |
|
862 | 861 | |
863 | - if ( ! empty( $mu_plugin_data['PluginURI'] ) ) { |
|
862 | + if ( ! empty($mu_plugin_data['PluginURI'])) { |
|
864 | 863 | $plugin_name = sprintf( |
865 | 864 | '<a href="%s" title="%s">%s</a>', |
866 | - esc_url( $mu_plugin_data['PluginURI'] ), |
|
867 | - esc_attr__( 'Visit plugin homepage', 'give' ), |
|
865 | + esc_url($mu_plugin_data['PluginURI']), |
|
866 | + esc_attr__('Visit plugin homepage', 'give'), |
|
868 | 867 | $plugin_name |
869 | 868 | ); |
870 | 869 | } |
871 | 870 | |
872 | 871 | // Link the author name to the author URL if available. |
873 | - $author_name = esc_html( $mu_plugin_data['Author'] ); |
|
872 | + $author_name = esc_html($mu_plugin_data['Author']); |
|
874 | 873 | |
875 | - if ( ! empty( $mu_plugin_data['AuthorURI'] ) ) { |
|
874 | + if ( ! empty($mu_plugin_data['AuthorURI'])) { |
|
876 | 875 | $author_name = sprintf( |
877 | 876 | '<a href="%s">%s</a>', |
878 | - esc_url( $mu_plugin_data['AuthorURI'] ), |
|
877 | + esc_url($mu_plugin_data['AuthorURI']), |
|
879 | 878 | $author_name |
880 | 879 | ); |
881 | 880 | } |
@@ -883,7 +882,7 @@ discard block |
||
883 | 882 | <tr> |
884 | 883 | <td><?php echo $plugin_name; ?></td> |
885 | 884 | <td class="help"> </td> |
886 | - <td><?php echo sprintf( _x( 'by %s', 'by author', 'give' ), $author_name ) . ' – ' . esc_html( $mu_plugin_data['Version'] ); ?></td> |
|
885 | + <td><?php echo sprintf(_x('by %s', 'by author', 'give'), $author_name).' – '.esc_html($mu_plugin_data['Version']); ?></td> |
|
887 | 886 | </tr> |
888 | 887 | <?php |
889 | 888 | } |
@@ -896,53 +895,53 @@ discard block |
||
896 | 895 | <table class="give-status-table widefat" cellspacing="0"> |
897 | 896 | <thead> |
898 | 897 | <tr> |
899 | - <th colspan="3" data-export-label="Theme"><h2><?php _e( 'Theme', 'give' ); ?></h2></th> |
|
898 | + <th colspan="3" data-export-label="Theme"><h2><?php _e('Theme', 'give'); ?></h2></th> |
|
900 | 899 | </tr> |
901 | 900 | </thead> |
902 | 901 | <?php |
903 | - include_once( ABSPATH . 'wp-admin/includes/theme-install.php' ); |
|
902 | + include_once(ABSPATH.'wp-admin/includes/theme-install.php'); |
|
904 | 903 | $active_theme = wp_get_theme(); |
905 | 904 | ?> |
906 | 905 | <tbody> |
907 | 906 | <tr> |
908 | - <td data-export-label="Name"><?php _e( 'Name', 'give' ); ?>:</td> |
|
909 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The name of the current active theme.', 'give' ) ); ?></td> |
|
910 | - <td><?php echo esc_html( $active_theme->Name ); ?></td> |
|
907 | + <td data-export-label="Name"><?php _e('Name', 'give'); ?>:</td> |
|
908 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The name of the current active theme.', 'give')); ?></td> |
|
909 | + <td><?php echo esc_html($active_theme->Name); ?></td> |
|
911 | 910 | </tr> |
912 | 911 | <tr> |
913 | - <td data-export-label="Version"><?php _e( 'Version', 'give' ); ?>:</td> |
|
914 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The installed version of the current active theme.', 'give' ) ); ?></td> |
|
915 | - <td><?php echo esc_html( $active_theme->Version ); ?></td> |
|
912 | + <td data-export-label="Version"><?php _e('Version', 'give'); ?>:</td> |
|
913 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The installed version of the current active theme.', 'give')); ?></td> |
|
914 | + <td><?php echo esc_html($active_theme->Version); ?></td> |
|
916 | 915 | </tr> |
917 | 916 | <tr> |
918 | - <td data-export-label="Author URL"><?php _e( 'Author URL', 'give' ); ?>:</td> |
|
919 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The theme developer\'s URL.', 'give' ) ); ?></td> |
|
917 | + <td data-export-label="Author URL"><?php _e('Author URL', 'give'); ?>:</td> |
|
918 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The theme developer\'s URL.', 'give')); ?></td> |
|
920 | 919 | <td><?php echo $active_theme->{'Author URI'}; ?></td> |
921 | 920 | </tr> |
922 | 921 | <tr> |
923 | - <td data-export-label="Child Theme"><?php _e( 'Child Theme', 'give' ); ?>:</td> |
|
924 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'Whether the current theme is a child theme.', 'give' ) ); ?></td> |
|
922 | + <td data-export-label="Child Theme"><?php _e('Child Theme', 'give'); ?>:</td> |
|
923 | + <td class="help"><?php echo Give()->tooltips->render_help(__('Whether the current theme is a child theme.', 'give')); ?></td> |
|
925 | 924 | <td><?php |
926 | - echo is_child_theme() ? __( 'Yes', 'give' ) : __( 'No', 'give' ) . ' – ' . sprintf( __( 'If you\'re modifying Give on a parent theme you didn\'t build personally, then we recommend using a child theme. See: <a href="%s" target="_blank">How to Create a Child Theme</a>', 'give' ), 'https://codex.wordpress.org/Child_Themes' ); |
|
925 | + echo is_child_theme() ? __('Yes', 'give') : __('No', 'give').' – '.sprintf(__('If you\'re modifying Give on a parent theme you didn\'t build personally, then we recommend using a child theme. See: <a href="%s" target="_blank">How to Create a Child Theme</a>', 'give'), 'https://codex.wordpress.org/Child_Themes'); |
|
927 | 926 | ?></td> |
928 | 927 | </tr> |
929 | 928 | <?php |
930 | - if( is_child_theme() ) { |
|
931 | - $parent_theme = wp_get_theme( $active_theme->Template ); |
|
929 | + if (is_child_theme()) { |
|
930 | + $parent_theme = wp_get_theme($active_theme->Template); |
|
932 | 931 | ?> |
933 | 932 | <tr> |
934 | - <td data-export-label="Parent Theme Name"><?php _e( 'Parent Theme Name', 'give' ); ?>:</td> |
|
935 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The name of the parent theme.', 'give' ) ); ?></td> |
|
936 | - <td><?php echo esc_html( $parent_theme->Name ); ?></td> |
|
933 | + <td data-export-label="Parent Theme Name"><?php _e('Parent Theme Name', 'give'); ?>:</td> |
|
934 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The name of the parent theme.', 'give')); ?></td> |
|
935 | + <td><?php echo esc_html($parent_theme->Name); ?></td> |
|
937 | 936 | </tr> |
938 | 937 | <tr> |
939 | - <td data-export-label="Parent Theme Version"><?php _e( 'Parent Theme Version', 'give' ); ?>:</td> |
|
940 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The installed version of the parent theme.', 'give' ) ); ?></td> |
|
941 | - <td><?php echo esc_html( $parent_theme->Version ); ?></td> |
|
938 | + <td data-export-label="Parent Theme Version"><?php _e('Parent Theme Version', 'give'); ?>:</td> |
|
939 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The installed version of the parent theme.', 'give')); ?></td> |
|
940 | + <td><?php echo esc_html($parent_theme->Version); ?></td> |
|
942 | 941 | </tr> |
943 | 942 | <tr> |
944 | - <td data-export-label="Parent Theme Author URL"><?php _e( 'Parent Theme Author URL', 'give' ); ?>:</td> |
|
945 | - <td class="help"><?php echo Give()->tooltips->render_help( __( 'The parent theme developers URL.', 'give' ) ); ?></td> |
|
943 | + <td data-export-label="Parent Theme Author URL"><?php _e('Parent Theme Author URL', 'give'); ?>:</td> |
|
944 | + <td class="help"><?php echo Give()->tooltips->render_help(__('The parent theme developers URL.', 'give')); ?></td> |
|
946 | 945 | <td><?php echo $parent_theme->{'Author URI'}; ?></td> |
947 | 946 | </tr> |
948 | 947 | <?php } ?> |