%s

', $message ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } /** * Prevents the Customizer from being loaded on WordPress versions prior to 4.9. * * @since 1.0.0 * * @global string $wp_version WordPress version. */ function cambay_prevent_customize_load() { wp_die( sprintf( /* translators: %s: Installed WordPress version */ esc_html__( 'cambay requires at least WordPress version 4.9. You are running version %s. Please upgrade and try again.', 'cambay' ), $GLOBALS['wp_version'] // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ), '', [ 'back_link' => true ] ); } add_action( 'load-customize.php', 'cambay_prevent_customize_load' ); /** * Prevents the Theme Preview from being loaded on WordPress versions prior to 4.9. * * @since 1.0.0 * * @global string $wp_version WordPress version. */ function cambay_prevent_preview() { if ( isset( $_GET['preview'] ) ) { wp_die( sprintf( /* translators: %s: Installed WordPress version */ esc_html__( 'cambay requires at least WordPress version 4.9. You are running version %s. Please upgrade and try again.', 'cambay' ), $GLOBALS['wp_version'] // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ) ); } } add_action( 'template_redirect', 'cambay_prevent_preview' );