This file contains hidden or 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
// ------------------------------------------------------ | |
// custom login style for theme for site url/wp-login.php | |
// ------------------------------------------------------ | |
function childtheme_custom_login() { | |
echo '<link rel="stylesheet" type="text/css" href="' . get_bloginfo('stylesheet_directory') . '/customlogin.css" />'; | |
} | |
add_action('login_head', 'childtheme_custom_login'); |
This file contains hidden or 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
<?php | |
// ---------------------------------------------------------------------------------------- | |
// Redirect all non-logged-in users to the login page (private site). Add to functions.php. | |
// ---------------------------------------------------------------------------------------- | |
function admin_redirect() { | |
if ( !is_user_logged_in()) { | |
wp_redirect( home_url('/wp-admin/') ); | |
exit; | |
} |
This file contains hidden or 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
// Add Twitter, Facebook and Google+ field to contact methods, remove AIM, YIM and Jabber | |
add_filter( 'user_contactmethods', 'ts_add_contact_fields' ); | |
function ts_add_contact_fields( $contactmethods ) { | |
$contactmethods['linkedin'] = 'LinkedIn'; | |
$contactmethods['twitter'] = 'Twitter'; | |
$contactmethods['facebook'] = 'Facebook'; | |
$contactmethods['googleplus'] = 'Google+'; | |
NewerOlder