WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Changing the background image on the posts page (3 posts)

  1. CSSLover
    Member
    Posted 1 year ago #

    Hello!

    I am attempting to put a different background image on each page of my site - per my client's request - and cannot seem to make any changes to the post page. I have used the page-id to try to target it in the style-sheet, but to no avail. (This worked fine, though, for all the other pages.) Is there a different method required for the page with the Loop? Or is it even possible? I've tried searching for help, but nothing has shown up for my particular problem; I would greatly appreciate some insight and help!

    Thank you in advance! :)

    Here's the sandbox:
    http://www.lachelndesigns.com/alzens/news/

    Here's the CSS style I used:

    .page-id-15  #page {
    	background-image: url('http://lachelndesigns.com/alzens/wp-content/uploads/2012/10/main-header-4.jpg');
    }
  2. Andrew Bartel
    Member
    Posted 1 year ago #

    The .page-id-somenumber class is being attached to the body tag. You'll notice on the news page that there is no page id (because it's just a post list page?)

    It does look like you have the unique .blog class though in the body tag for the news page.

    So, you could do:

    .blog #page {
    // your background image css
    }

    Tools like firebug are really useful for this kind of css work.

    Nice looking site.

  3. CSSLover
    Member
    Posted 1 year ago #

    Andrew -

    That did it! Thank you for taking the time to help me out! I'll have to look into Firebug...

    Thanks! :)

Topic Closed

This topic has been closed to new replies.

About this Topic