Getting ads to show above the title on standard pages and posts
-
Hi there I want an ad to show below our logo, primary nav and breadcrumbs, but above the page title. I want it to show on our standard posts and standard pages. (I have included a link to one of those.) In our theme files, we have Single Post (single.php) and Single Page (page.php). We also have Theme Header (header.php). We have custom templates for other pages, and we have the home page, archive pages and author pages. I don't want it to show on those, which all have separate theme files. I've received a little advice as well as links to some help pages from Advanced Ads customer support, but I'm finding it just a little beyond me. The four things I'm trying to find out/solve/confirm are: 1. I currently have the free version of Advanced Ads. Customer support tells me I can achieve what I want with the free version. Does that match your experience? 2. What specific settings do I need to select in the Advanced Ads? 3. What precise code do I insert, in which theme file(s), and where exactly do I insert the code (which row) in that file/those files? 4. Do I need to insert the short code anywhere as well/instead? Regarding number three on that list, if it goes in header.php, the last few rows of our header are: ============================ <?php //<div class="breadcrumb mb-5 lg:mb-16"> ?> <?php //} ?> <?php if ( function_exists('yoast_breadcrumb') ) { ?? yoast_breadcrumb( '<p id="breadcrumbs">','</p>' ); } ?> <?php //if(function_exists('bcn_display')) { bcn_display(); } ?> </div> <?php } ?> <?php do_action( 'tailpress_content_start' ); ?> <main> ============================ If it goes in single.php and page.php, the opening rows in single.php (page.php is very similar) are: ============================ <?php get_header(); global $post;? ?> <div class="container mx-auto my-8 px-0"> <div class="max-w-2xl mx-auto single_post_page"> <h1 class="title-box ft-arvo text-4xl font-bold text-gray-900 leading-10 mb-4 lg:px-6"><?=get_the_title()?></h1> <?php if ( !in_category('Guides') ) { ?> ============================ In case you need it, for my ad: The shortcode is [the_ad id="35670"] The template (PHP) code is <?php the_ad('35670'); ?> If it helps, I have assigned the ad to a group, although it's the only ad in the group. The ad is currently in draft. Thank you very much for any assistance! Neil
The page I need help with: [log in to see the link]
Viewing 11 replies - 1 through 11 (of 11 total)
Viewing 11 replies - 1 through 11 (of 11 total)
- The topic ‘Getting ads to show above the title on standard pages and posts’ is closed to new replies.