the home page usually has a body class of .home — check the <body> tag on your home page.
You can then use that to be very specific with your CSS. For example,
.home body { background: url(‘some_image_file.png’); }
Thanks sterndata.
I haven’t played around with much CSS yet, but I’m happy to try if you can be a little more specific.
I’m not familiar with the process, but I’m hoping my intelligence and some help should get me through it!
Am I looking for the tag in the editor? Under Styles? Or Templates?
Under styles I have found:
body{color:#555555; font-family:’Open Sans’,Arial, FontAwesome, sans-serif; font-size:14px;line-height:1.5;word-wrap:break-word; font-weight: 100; min-width: 1300px; background: #FFFFFF; }
.site-container { width: 100%; display: block; margin: 0 auto; overflow: hidden; }
… but it doesn’t look like it’s talking about the front page.
Under templates there’s a Static Front Page (front-page.php) link, but the only thing in that entire space is:
*/
?>
<?php get_header(); ?>
<div class=”clear-top”></div>
<?php if ( ‘posts’ == get_option( ‘show_on_front’ ) ) : get_template_part( ‘fp-blog’ );
else: get_template_part( ‘featured-box’ ); get_template_part( ‘fcontent’ );
endif;
get_footer(); ?>
Sorry, I know I’m a pain, but I’m very happy to learn if anyone has a bit of patience..?!
Please give me a link to your site.
Thanks!
http://www.coreintentions.com
It’s a giant mess right now, I am fumbling through!
I just published it, let me know when you’re done so I can remove it from being out there in the world!
I am able to add a background image, and it will show on the front page, but then it also shows on all the rest, and you can’t read the text.
Maybe it’s easier to change those than the front page..?
just qualify it with .home
.home .body and so on
home is a class of the body.
The correct CSS code should be this:
body.home{background: url('http://i1.wp.com/www.coreintentions.com/wp-content/uploads/2016/05/cropped-23-01.png?fit=250%2C70');}
I used your logo as an example. 🙂
I’m not sure where to add that to qualify it.. sorry.
It seems really simple.. but only if you speak the language!
thanks for the correction, bryan!
You add the code under Appearance > Editor > style.css
Just be careful not to delete any other code in there. To be safe, add it at the bottom.
Bryan and sterndata..
You have no idea how much I appreciate this.
I copied exactly what you suggested I add, and added it to the bottom of style.css and after I updated, nothing changed 🙁
I understand if you think I’m a lost cause, but I would still like to try if anyone has any suggestions!
The site is back on maintenance mode, I can’t have that mess out there!
You might want to check if your CSS has been added successfully. Can you disable the maintenance mode for a little while so that I can view the theme’s stylesheet?
Your website now just displays a white page.