Changeset 48172 for trunk/src/wp-admin/includes/plugin.php
- Timestamp:
- 06/26/2020 12:25:15 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/plugin.php
r48142 r48172 1149 1149 $compatible_php = is_php_version_compatible( $requirements['requires_php'] ); 1150 1150 1151 /* translators: %s: URL to Update PHP page. */ 1152 $php_update_message = '</p><p>' . sprintf( 1153 __( '<a href="%s">Learn more about updating PHP</a>.' ), 1154 esc_url( wp_get_update_php_url() ) 1155 ); 1156 1157 $annotation = wp_get_update_php_annotation(); 1158 1159 if ( $annotation ) { 1160 $php_update_message .= '</p><p><em>' . $annotation . '</em>'; 1161 } 1162 1151 1163 if ( ! $compatible_wp && ! $compatible_php ) { 1152 1164 return new WP_Error( 1153 1165 'plugin_wp_php_incompatible', 1154 sprintf( 1155 /* translators: %s: Plugin name. */ 1156 _x( '<strong>Error:</strong> Current WordPress and PHP versions do not meet minimum requirements for %s.', 'plugin' ), 1157 $plugin_headers['Name'] 1158 ) 1166 '<p>' . sprintf( 1167 /* translators: 1: Current WordPress version, 2: Current PHP version, 3: Plugin name, 4: Required WordPress version, 5: Required PHP version. */ 1168 _x( '<strong>Error:</strong> Current versions of WordPress (%1$s) and PHP (%2$s) do not meet minimum requirements for %3$s. The plugin requires WordPress %4$s and PHP %5$s.', 'plugin' ), 1169 get_bloginfo( 'version' ), 1170 phpversion(), 1171 $plugin_headers['Name'], 1172 $requirements['requires'], 1173 $requirements['requires_php'] 1174 ) . $php_update_message . '</p>' 1159 1175 ); 1160 1176 } elseif ( ! $compatible_php ) { 1161 1177 return new WP_Error( 1162 1178 'plugin_php_incompatible', 1163 sprintf( 1164 /* translators: %s: Plugin name. */ 1165 _x( '<strong>Error:</strong> Current PHP version does not meet minimum requirements for %s.', 'plugin' ), 1166 $plugin_headers['Name'] 1167 ) 1179 '<p>' . sprintf( 1180 /* translators: 1: Current PHP version, 2: Plugin name, 3: Required PHP version. */ 1181 _x( '<strong>Error:</strong> Current PHP version (%1$s) does not meet minimum requirements for %2$s. The plugin requires PHP %3$s.', 'plugin' ), 1182 phpversion(), 1183 $plugin_headers['Name'], 1184 $requirements['requires_php'] 1185 ) . $php_update_message . '</p>' 1168 1186 ); 1169 1187 } elseif ( ! $compatible_wp ) { 1170 1188 return new WP_Error( 1171 1189 'plugin_wp_incompatible', 1172 sprintf( 1173 /* translators: %s: Plugin name. */ 1174 _x( '<strong>Error:</strong> Current WordPress version does not meet minimum requirements for %s.', 'plugin' ), 1175 $plugin_headers['Name'] 1176 ) 1190 '<p>' . sprintf( 1191 /* translators: 1: Current WordPress version, 2: Plugin name, 3: Required WordPress version. */ 1192 _x( '<strong>Error:</strong> Current WordPress version (%1$s) does not meet minimum requirements for %2$s. The plugin requires WordPress %3$s.', 'plugin' ), 1193 get_bloginfo( 'version' ), 1194 $plugin_headers['Name'], 1195 $requirements['requires'] 1196 ) . '</p>' 1177 1197 ); 1178 1198 }
Note: See TracChangeset
for help on using the changeset viewer.