• 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

Agency Pro – Custom Backgrounds for Pages & Posts

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 › Design Tips and Tricks › Agency Pro – Custom Backgrounds for Pages & Posts

This topic is: not resolved

Tagged: agency pro, background image, custom background, featured image, genesis

  • This topic has 5 replies, 2 voices, and was last updated 8 years, 6 months ago by fr06.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • August 25, 2014 at 6:31 am #120882
    fr06
    Member

    Hiya!

    We're using Agency Pro theme (v.3.1.1) and Genesis Framework (v.2.1.2) but wanted some pages to have a different background image. We looked at custom background plugins we found that many of them no longer seem to be supported. Agency Pro already had the functionality for adding a custom background image but we needed it to go a little further and if a page/post had a set Featured Image to use that image as the background instead of our default.

    In the end I modified some php code to get the functionality we needed. To do this head to your functions.php file and look for this section:

    I Modified the above section to become:

    We added our custom default image by FTP into our theme/images folder. Basically what this is saying is that if it's a page or post and has a featured image then use the featured image as a background image. If there is no featured image then use the default background in our theme/images folder.

    August 25, 2014 at 6:46 am #120884
    Genesis Developer
    Member

    How are you getting featured image option for page? By default there have no featured image option for pages. Are you using any plugin?

    For custom background image you'll use custom field option. There have a good plugin for this ( try Advanced Custom Fields plugin). It is working with Genesis. You will call a hook and write a custom code in your functions.php file.


    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

    August 25, 2014 at 8:28 am #120905
    fr06
    Member

    Hi genwrock:

    Thanks for your reply! I tested the Featured Image functionality in a clean WordPress site without Genesis or plugins and used a standard out of the box WP theme. I could see the featured image option on my page in the edit view. Have you checked that "Featured Image" is box is checked in your page screen options (on edit page)?

    Thanks for the plugin, I'll take a look and see if we could use it on other builds! For this site we really wanted to limit the number of plugins as it's a large site and sometimes plugin functionality can conflict. For us this PHP code was easy to add to our modified child theme and used WP functionality which is exactly what we wanted!

    August 25, 2014 at 8:53 am #120911
    Genesis Developer
    Member

    Ahh... Yes. I just checked it. sorry for miss-understanding. Then it'll be quite easy and not require any plugin. Let me know you are getting functionality for your site. Otherwise I can write and test the code for you.


    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

    August 25, 2014 at 8:55 am #120912
    Genesis Developer
    Member

    Lol. full code is here http://sridharkatakam.com/set-featured-image-full-sized-background-posts-pages-wordpress/ . This is for you.


    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

    August 25, 2014 at 10:01 am #120925
    fr06
    Member

    Lol that's actually one of the posts I used as my jumping off point but I had to adapt it to function with a theme that already had script files. I've tested it on a couple of sites with other themes and it's working beautifully! Thanks 🙂

  • Author
    Posts
Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

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

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 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