From 64b021bbce8b7e074e9180129c2d5f8e1c2af742 Mon Sep 17 00:00:00 2001 From: Helen Hou-Sandi Date: Wed, 25 Sep 2013 15:19:11 +0000 Subject: [PATCH] Simplify the login page viewport meta for mobile devices, so it's less restrictive on the user. Allows for developers to override if necessary via the `login_head` action. props azaozz. fixes #24777. git-svn-id: https://develop.svn.wordpress.org/trunk@25619 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-login.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/wp-login.php b/src/wp-login.php index 3cda41c3ff..6513f777ce 100644 --- a/src/wp-login.php +++ b/src/wp-login.php @@ -44,6 +44,9 @@ function login_header($title = 'Log In', $message = '', $wp_error = '') { // Don't index any of these forms add_action( 'login_head', 'wp_no_robots' ); + if ( wp_is_mobile() ) + add_action( 'login_head', 'wp_login_viewport_meta' ); + if ( empty($wp_error) ) $wp_error = new WP_Error(); @@ -64,10 +67,6 @@ function login_header($title = 'Log In', $message = '', $wp_error = '') { wp_admin_css( 'wp-admin', true ); wp_admin_css( 'colors-fresh', true ); - if ( wp_is_mobile() ) { ?> - + +