Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1173702
    mrbizkid13
    Participant

    Hi,

    Using Ethos, I want to add a banner in the header area for Adsense. Can you please advise as to the best way of doing this?

    Thanks…

    #1173992
    Jade
    Moderator

    Hi there,

    You may follow the suggestion on this link: http://www.wpbeginner.com/beginners-guide/how-to-add-google-adsense-to-your-wordpress-site/

    Let us know if you need further help.

    #1175487
    mrbizkid13
    Participant

    Please let me clarify: I am asking for help positioning a banner in the header area using Ethos. The four widget areas do not accommodate a single horizontal banner.

    Thank you

    #1175964
    Friech
    Moderator

    Hi There,

    Please provide us your site URL so we can take a closer look, and perhaps some screenshot on how you want the banner to be positioned on the header.

    We’ll be happy to provide you with a response once we have a better understanding of the situation.

    Thanks.

    #1177052
    mrbizkid13
    Participant
    #1177061
    mrbizkid13
    Participant

    Forgot to add: banner in the header area above the image and below the social media bar – if possible. If not, then as long as its in the header area it will work.

    #1177296
    Jade
    Moderator

    Hi there,

    Your site seems to be not loading at the moment. Is this the correct link you have provided? Kindly double check. Thank you.

    #1178481
    mrbizkid13
    Participant

    Sorry – you can view it now. Thanks

    #1179010
    Friech
    Moderator

    Hi There,

    On your child theme, navigate to this directory \x-child\framework\views\ethos\. There create a file named wp-header.php and paste the code below on it.

    <?php
    
    // =============================================================================
    // VIEWS/ETHOS/WP-HEADER.PHP
    // -----------------------------------------------------------------------------
    // Header output for Ethos.
    // =============================================================================
    
    ?>
    
    <?php x_get_view( 'global', '_header' ); ?>
    
      <?php x_get_view( 'global', '_slider-above' ); ?>
    
      <header class="<?php x_masthead_class(); ?>" role="banner">
        <?php x_get_view( 'ethos', '_post', 'carousel' ); ?>
        <?php x_get_view( 'global', '_topbar' ); ?>
        <div class="ad-banner x-container max width">
        	
    <!-- PASTE YOUR ADS BANNER CODE HERE -->
    
        </div>
        <?php x_get_view( 'global', '_navbar' ); ?>
        <?php x_get_view( 'ethos', '_breadcrumbs' ); ?>
      </header>
    
      <?php x_get_view( 'global', '_slider-below' ); ?>
      <?php x_get_view( 'ethos', '_landmark-header' ); ?>

    Replace the <!-- PASTE YOUR ADS BANNER CODE HERE --> part with your actual ad banner code.

    Hope it helps, Cheers!

    #1179371
    mrbizkid13
    Participant

    Hi

    I created the file with the provided code, and it did not work. The file (-content/themes/x-child/framework/views/ethos/wp-header.php ) is not showing as a php file (screen shot attached).

    Thanks…

    #1179412
    Thai
    Moderator

    Hi There,

    Please provide us with your FTP account so we can take a closer look.

    Thanks.

    #1180318
    mrbizkid13
    Participant
    This reply has been marked as private.
    #1180516
    Lely
    Moderator

    Hi There,

    I have created the file and added on the same folder. Then remove the other file. Feel free to download that file and then edit it and upload again.

    Hope this helps.

    #1181755
    mrbizkid13
    Participant

    Hi – great, thank you. I’m just not clear from your note what you mean by ‘Then remove the other file’?

    Once this has been successfully implemented, how do I activate the banner area? Shortcode? Widget?

    Thanks very much!

    #1182162
    Friech
    Moderator

    Hi There,

    Lely means, she remove the other wp-header.php file (the one that you created).

    The banner code will be hardcoded on wp-header.php file. Please login to your FTP and edit the file wp-header.php (that Lely created). Look for the line <!-- PASTE YOUR ADS BANNER CODE HERE --> and replace that with your actual banner code.

    The banner should show between the maroon and black area of your header.

    Hope it helps, Cheers!

  • <script> jQuery(function($){ $("#no-reply-1173702 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>