Title: Background Image for posts
Last modified: August 20, 2016

---

# Background Image for posts

 *  Resolved [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * (@keller-bear)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/)
 * Hi. I’m using the very good Two post columns Twenty Eleven child theme by Digital
   Raindrops and wanted to add a background image to each post excerpt on the blog
   page.
 * Very easily I added some css:
 *     ```
       article {
       	background-image: url(Images/black_board.jpg);
       	background-repeat: no-repeat;
       }
       ```
   
 * But this creates a number of problems.
 * 1. – This image is also added to the pages with single post.
    2. – This image
   was added to the comments (RESOLVED) 3. – I want to direct some css to the h1.
   entry-title on the page with the grid of posts (namely add a bit of margin to
   push it away from the edge of the image) but know if I do that then the single
   post pages will be pushed accordingly. ** How do I get rid of the images on the
   single post and also target the h1.entry-title on the two column page only?

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Thread Starter [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * (@keller-bear)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880104)
 * Just to add, I realise I could target the next outer div e.g. article#post-9 
   but this would be useless as I would have to have separate css for each and every
   post number in the future.
 * Help greatly appreciated!!
 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880266)
 * it might help if you can post a link to your site to illustrate the problem.
 * generally, look into the existing page specific body_class output;
 * [http://codex.wordpress.org/Function_Reference/body_class](http://codex.wordpress.org/Function_Reference/body_class)
 * for instance `.blog` for the posts page;
    or `.single` for single posts.
 *  Thread Starter [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * (@keller-bear)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880273)
 * Hi alchymyth
 * I am still working on the site locally and really haven’t changed anything of
   great significance.
 * I did manage to write in some css that solved half my problem
 * .page article {
    background-image: none; }
 * .single article {
    background-image: none; }
 * So really my third problem just remains. Do I need to go into single.php and 
   add a style directly in there or is this a complete no-no and styling should 
   be kept in the css file?
 * Also, I’m having another problem (and your name keeps popping up so I was hoping
   I would get your attention!!) that you might have a look at if you have time?
   it can be found at:
 * [link](http://wordpress.org/support/topic/twentyeleven-landing-page-that-displays-2-of-the-latest-posts-from-a-blog-page-1?replies=5#post-2969220)
 *  [Michael](https://wordpress.org/support/users/alchymyth/)
 * (@alchymyth)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880276)
 * > direct some css to the h1.entry-title on the page with the grid of posts
 * check the css class in the body tag of that (web) page; possibly use a tool such
   as Firebug [http://getfirebug.com/](http://getfirebug.com/)
 * if that is the posts page (blog page), the css class might be `.blog`
 * i.e. to format the h1 on the grid posts page only, possibly use:
 * `.blog h1.entry-title { ... }`
 *  Thread Starter [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * (@keller-bear)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880277)
 * ok I will try that out, thanks. Will let you know if it works!
 *  Thread Starter [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * (@keller-bear)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880340)
 * Thanks alchymyth, this worked a treat!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Background Image for posts’ is closed to new replies.

## Tags

 * [background](https://wordpress.org/support/topic-tag/background/)
 * [child theme](https://wordpress.org/support/topic-tag/child-theme/)
 * [image](https://wordpress.org/support/topic-tag/image/)

 * 6 replies
 * 2 participants
 * Last reply from: [Keller Bear](https://wordpress.org/support/users/keller-bear/)
 * Last activity: [13 years, 11 months ago](https://wordpress.org/support/topic/background-image-for-posts/#post-2880340)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
