• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

AdSense code below Page/Post title?

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › AdSense code below Page/Post title?

This topic is: not resolved
  • This topic has 3 replies, 2 voices, and was last updated 13 years, 1 month ago by Debra Scott.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • June 13, 2013 at 9:49 am #45674
    [email protected]
    Participant

    How can I add AdSense code below a Page (and Post) title but before the content? I found a plugin but it only inserts the ad below the content on just posts, not pages with no options for adding the ads to pages or above the content.

    June 13, 2013 at 10:28 am #45682
    Debra Scott
    Member

    try this in functions.php - style using .postad in style.css

    add_action('genesis_after_post_title', 'child_include_postad');
    /**
     * Add post ad after titles
    * @author Debra Scott Fat Cat Designs
     */
    function child_include_postad() {?>
     <div class="postad">
    Google Code Here
     </div> <?php
    }

    NOTE: this hook will need to be altered after upgrading to WordPress 3.6 and Genesis 2.0


    need help with your business or personal website? Contact me at Fat Cat Designs

    June 13, 2013 at 10:45 am #45686
    [email protected]
    Participant

    Thanks, that works!

    June 13, 2013 at 10:47 am #45687
    Debra Scott
    Member

    You're welcome!


    need help with your business or personal website? Contact me at Fat Cat Designs

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘AdSense code below Page/Post title?’ is closed to new replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble