Tagged: x
-
AuthorPosts
-
March 8, 2017 at 1:45 pm #1399518
abolianParticipantHello there,
I want to show google adsense ads correctlyi have added the code as following in function.php
<?php // ============================================================================= // FUNCTIONS.PHP // ----------------------------------------------------------------------------- // Overwrite or add your own custom functions to X in this file. // ============================================================================= // ============================================================================= // TABLE OF CONTENTS // ----------------------------------------------------------------------------- // 01. Enqueue Parent Stylesheet // 02. Additional Functions // ============================================================================= // Enqueue Parent Stylesheet // ============================================================================= add_filter( 'x_enqueue_parent_stylesheet', '__return_true' ); // Additional Functions // ============================================================================= add_filter('the_content', 'display_author_box', 999999); function display_author_box ( $content ) { return is_singular('post') ? $content.do_shortcode('[author title="About the Author"]') : $content; } // add_action('wp_head', 'custom_scripts'); function custom_scripts() { ?> <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script> <script> (adsbygoogle = window.adsbygoogle || []).push({ google_ad_client: "ca-pub-2281927822397133", enable_page_level_ads: true }); </script> <?php }but the problem is that on desktop and mobile not shown as expected,
before disabled the adsense plugin (as google asked to disable it)
it was autmaticly place the ads on each page 3 ads
on top and bottom and the middlebut now, by this code — and reference to this link
there’s a note that layout of theme should be able to serve the ads and has spaces,
as you see my “home page” for example
only at bottom one ads – no other than that,
Thanks
March 8, 2017 at 4:16 pm #1399723
NicoModeratorHi There,
Thanks for writing in.
In this case, to check your setup furthere, would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:
– Link to your site
– WordPress Admin username / password
– FTP credentialsDon’t forget to select Set as private reply. This ensures your information is only visible to our staff.
Thanks.
March 8, 2017 at 10:29 pm #1400088
abolianParticipantThis reply has been marked as private.March 9, 2017 at 1:14 pm #1400895
RadModeratorThis reply has been marked as private. -
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1399518 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
