WordPress.org

Support

Support » How-To and Troubleshooting » [Resolved] background for single post?

[Resolved] background for single post?

  • http://bizbuzmarketing.com/wordpress/?p=1

    Hi,

    I’ve used the code below to incorporate a background for the home page and another other pages. I’d like to add the latter image for single posts (single.php). I”m not talking about a post background, but a background for the whole page displaying the post. Can anyone advise?

    Thanks for any help you can give,

    Max

    <?php if (is_home()): ?>
    	<style type="text/css">
    	body {background: url(http://bizbuzmarketing.com/wordpress/wp-content/themes/toolbox/images/bb-bkgd.jpg); background-position: left top; background-repeat: no-repeat;}
    	</style>
    <?php elseif (is_page() ): ?>
    	<style type="text/css">
    	body {background: url(http://bizbuzmarketing.com/wordpress/wp-content/themes/toolbox/images/bb-bkgd-2.jpg); background-position: center top; background-repeat: no-repeat;}
    	</style>
    <?php endif; ?>

    [Please post code snippets between backticks or use the code button.]

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] background for single post?’ is closed to new replies.