Support » Theme: Goran » No Site Logo option in Customizer

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator Kathryn

    (@zoonini)

    Automattic Happiness Engineer

    Hi – @ppica – Goran was developed before site-logo support was part of WordPress core, so you’ll need to activate the Jetpack plugin to get the functionality.

    function theme_prefix_setup() {

    add_theme_support( ‘custom-logo’, array(
    ‘height’ => 500,
    ‘width’ => 500,
    ‘flex-width’ => true,
    ) );

    }
    add_action( ‘after_setup_theme’, ‘theme_prefix_setup’ );

    Add above code in functions.php file
    to output logo
    function theme_prefix_the_custom_logo() {

    if ( function_exists( ‘the_custom_logo’ ) ) {
    the_custom_logo();
    }

    }

    now in html file where to logo have to be displayed
    write following code
    <?php $custom_logo_id = get_theme_mod( ‘custom_logo’ );
    $image = wp_get_attachment_image_src( $custom_logo_id , ‘full’ );
    ?>
    ” alt=”Logo”>

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘No Site Logo option in Customizer’ is closed to new replies.