Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I am trying to make custom login page by adding 1 in functions.php and 2 into theme folder. but I can't even execute the theme. I can activate the theme without 1 and 2. However, the site goes frozen both way trying to update the functions.php after pushing 2 to server and modifying the functions.php on dashboard, and trying to activate the theme after pushing the theme including 1,2 to server. The file is available at www.lastech.com.au/green.zip I tried so many different way to sort this out but it is not working. I spent almost a week. Please help me guys!

1.

function custom_login() { 
echo '<link rel="stylesheet" type="text/css" href="'.get_bloginfo('template_directory').'/custom-login.css" />'; 
}
add_action('login_head', 'custom_login');

2.

custom-login.css file

My file is available at www.lastech.com.au/green.zip

Regards

BK

share|improve this question
1  
could you please clarify the question what exactly is the problem? –  BandonRandon Mar 28 '12 at 7:14
add comment

2 Answers

What i do is create a page normally in the dashboard, call it something like 'login', then use filters to replace the wordpress login url:

/**
* change http://www.google.ie to the url to your custom page, or anything you like
* @return string
*/
function my_login_url(){
    return "http://www.google.ie";
}
add_filter('login_url', 'my_login_url');

make sure you include it somewhere near the top of your functions file for themes or the index.php plugin_name.php file for plugins.

then anywhere in the wordpress blog wp_login_url() is called, using the above example, it will give a link to: 'http://www.google.ie'

Just came across this for renaming wp-admin: http://wordpress.org/support/topic/anyone-tried-wp-reloaded

share|improve this answer
add comment

Replace the above with this:

    // Custom login css
function my_custom_login() {        
    echo "<link rel='stylesheet' href='". get_bloginfo('template_directory') ."/custom-login.css' type='text/css' media='screen' />\n";
}
add_action('login_head', 'my_custom_login');

    // Change the logo url from wordpress to the one you want   
function login_url(){       
    return home_url();      
}
add_filter('login_headerurl', 'login_url');

// Change the logo title from standard to the blog name
function login_title(){
    return get_bloginfo('name');
}
add_filter('login_headertitle', 'login_title');
share|improve this answer
    
You should have a look at the differences between actions and filters. –  chrisguitarguy Mar 28 '12 at 13:32
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.