summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'themes/twentyfifteen/inc/back-compat.php')
-rw-r--r--themes/twentyfifteen/inc/back-compat.php24
1 files changed, 20 insertions, 4 deletions
diff --git a/themes/twentyfifteen/inc/back-compat.php b/themes/twentyfifteen/inc/back-compat.php
index a4f03e3a..6b871f5e 100644
--- a/themes/twentyfifteen/inc/back-compat.php
+++ b/themes/twentyfifteen/inc/back-compat.php
@@ -34,8 +34,14 @@ add_action( 'after_switch_theme', 'twentyfifteen_switch_theme' );
* @since Twenty Fifteen 1.0
*/
function twentyfifteen_upgrade_notice() {
- $message = sprintf( __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ), $GLOBALS['wp_version'] );
- printf( '<div class="error"><p>%s</p></div>', $message );
+ printf(
+ '<div class="error"><p>%s</p></div>',
+ sprintf(
+ /* translators: %s: WordPress version. */
+ __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ),
+ $GLOBALS['wp_version']
+ )
+ );
}
/**
@@ -45,7 +51,11 @@ function twentyfifteen_upgrade_notice() {
*/
function twentyfifteen_customize() {
wp_die(
- sprintf( __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ), $GLOBALS['wp_version'] ),
+ sprintf(
+ /* translators: %s: WordPress version. */
+ __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ),
+ $GLOBALS['wp_version']
+ ),
'',
array(
'back_link' => true,
@@ -61,7 +71,13 @@ add_action( 'load-customize.php', 'twentyfifteen_customize' );
*/
function twentyfifteen_preview() {
if ( isset( $_GET['preview'] ) ) {
- wp_die( sprintf( __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ), $GLOBALS['wp_version'] ) );
+ wp_die(
+ sprintf(
+ /* translators: %s: WordPress version. */
+ __( 'Twenty Fifteen requires at least WordPress version 4.1. You are running version %s. Please upgrade and try again.', 'twentyfifteen' ),
+ $GLOBALS['wp_version']
+ )
+ );
}
}
add_action( 'template_redirect', 'twentyfifteen_preview' );