WordPress.org

Ready to get started?Download WordPress

Forums

Preference Lite
[resolved] Page-Top-Background Image (3 posts)

  1. sitecrafter
    Member
    Posted 5 months ago #

    Hello

    As per previous post
    I would like to keep the top half different to the bottom - however I would like to add an image to the top half... I tried the above and took out the php code (in the child theme) but this leaves me with no top half and I don't know how to add the image just for the top?? (I am sorry if this doesn't make sense)

    ps. beautiful theme, thank you!
    pps. sorry for posting on resolved post :(

  2. StyledThemes
    Member
    Theme Author

    Posted 5 months ago #

    Thanks for the re-post. I know some people have done the top half as an image, but you will have to do some custom changes. This is the part in the header.php that does the top half:

    <div id="page-top-bg" style="border-color: <?php echo get_theme_mod( 'page_top_border', '#595A67' ); ?>; border-bottom-color: <?php echo get_theme_mod( 'tophalf_botline', '#BCBCBC' ); ?>; background-color:<?php echo get_theme_mod( 'tophalf_bg', '#ffffff' ); ?>;"></div>

    More specifically, this is the part which is tied in with the theme option settings to allow a background colour (just no image)

    background-color:<?php echo get_theme_mod( 'tophalf_bg', '#ffffff' ); ?>;

    You would need to take that out or comment out the code and create a custom CSS to load your background image to the "page-top-bg" container.

    I'm also hoping you will be using a child theme (which is included in the theme in a folder called "child-theme"), then copy the header.php over to that once you activated the theme. This allows you to keep the theme updated without losing your changes.

  3. sitecrafter
    Member
    Posted 5 months ago #

    Thank you!!

    I have done it now (woo hoo)

    I always use a child theme and appreciate that you included one in your theme!

    Thanks again... You are a star :)

Reply

You must log in to post.

About this Theme

About this Topic

Tags

No tags yet.