working on it ...


Explore Public Snippets

Sort by

Found 1 snippet matching: "customizing the wordpress logo in php"

    public by lbottaro  4876  10  7  0

    How to customize the WordPress Login Logo

    WordPress uses CSS to display a background image -- the WordPress logo -- in the link () inside the heading tag (). In this PHP example, the login_enqueue_scripts hook allows to insert CSS into the head of the login page so you can show your logo instead. You can replace the file named logo.png with the file-name of your logo, and store your logo
    function my_login_logo() { ?>
        <style type="text/css">
            body.login div#login h1 a {
                background-image: url(<?php echo get_bloginfo( 'template_directory' ) ?>/images/logo.png);
                padding-bottom: 30px;
    <?php }
    add_action( 'login_enqueue_scripts', 'my_login_logo' );

    List Complete ( 1 snippet total )

    Cannot find what you were looking for?
    Ask the Snip2Code Community

    • Public Snippets
    • Channels Snippets