• I’m building a site here – https://3c2.154.myftpupload.com, but since I’m not a programmer, I don’t know where to add the customize header logo in the header.php file. I have the code:

    [ Moderator note: Code fixed, please wrap code in backticks or use the code button. ]

    <?php if ( get_header_image() ) : ?>
    	<a>" rel="home">
    		<img src="<?php header_image(); ?>" width="<?php echo esc_attr( get_custom_header()->width ); ?>" height="<?php echo esc_attr( get_custom_header()->height ); ?>" alt="">
    	</a>
    	<?php endif; // End header image check. ?>
    
    I just don't know where to place it in the code below (header.php):
    
    <?php
    /**
     * The header for our theme.
     *
     * Displays all of the <head> section and everything up till <div id="content">
     *
     * @package adelia
     */
    global $redux_adelia;
    $favico = $style = '';
    if(isset($redux_adelia['adelia_faviconurl']) && !empty($redux_adelia['adelia_faviconurl']['url'])){
    	$favico = $redux_adelia['adelia_faviconurl']['url'];
    }else{
    	$favico = ADELIA_PATH . '/images/favicon.ico';
    }
    if(isset($redux_adelia['adelia_select_type']) && $redux_adelia['adelia_select_type'] == '2'){
    	$style = 'style="background-image:url('.ADELIA_PATH.'/images/patterns/'.esc_attr($redux_adelia['adelia_style_switcher_background']).')"';
    }
    global $post;
    ?><!DOCTYPE html>
    <html <?php language_attributes(); ?>>
    <head>
    <meta charset="<?php bloginfo( 'charset' ); ?>">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title><?php wp_title( '|', true, 'right' ); ?></title>
    <link rel="profile" href="https://gmpg.org/xfn/11">
    <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
    <link rel="icon" type="image/x-icon" href="<?php echo esc_url($favico); ?>" />
    <?php wp_head(); ?>
    </head>
    
    <body <?php body_class('wide color pattern-1'); ?> <?php echo esc_attr($style); ?>>
    <div id="wrapper">
    <?php
    /** header section **/
    get_template_part('include/section-header'); get_template_part('include/section-slider');
    $val = '';
    if(!is_search()){
    	if(!(class_exists( 'WooCommerce' ) && is_shop())){
    		$val = get_post_meta($post->ID,'adelia_slider_slider',true);
    	}
    }
    $position = get_sidebar_position();
    $clas_pos = '';
    if($position == 'left'){
    	$clas_pos = 'class="sbl"';
    }elseif($position == 'right'){
    	$clas_pos = 'class="sbr"';
    }
    ?>
    <div id="content" <?php if(empty($val)) echo esc_attr($clas_pos); ?>>
    <?php if(empty($val)) echo '<div class="menu-shadow"></div>'; ?>
    	<div class="container clearfix">
    	<?php if(is_home()){ echo '<div class="al_spacer clearfix"></div>'; } ?>
  • The topic ‘Custom header logo Adelia theme’ is closed to new replies.