Created
August 3, 2014 22:27
-
-
Save AllieRays/bdf9f09ba76a6ec2cacf to your computer and use it in GitHub Desktop.
Altering text on Drupal login pages
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function vod_preprocess_page(&$variables) { | |
// dpm($variables); | |
if ($variables['is_front'] == TRUE || arg(0) == 'home') { | |
$variables['title'] = ''; | |
} | |
if ($variables['logged_in'] == FALSE && arg(0) == 'user') { | |
$variables['title'] = 'Sign In'; | |
$variables['login_link'] = '<a href="/user/password" class="return-text">Forgot password?</a>'; | |
} | |
if ($variables['logged_in'] == FALSE && arg(1) == 'password') { | |
$variables['title'] = 'Request Password'; | |
$variables['login_link'] = '<a href="/user" class="return-text">Cancel</a>'; | |
} | |
if ($variables['logged_in'] == FALSE && arg(1) == 'register') { | |
$variables['title'] = 'Create an Account'; | |
$variables['login_link'] = '<a href="/user" class="return-text">Cancel</a>'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment