# I need help with writing a PHP conditional statement

**URL:** <https://forum.kirupa.com/t/i-need-help-with-writing-a-php-conditional-statement/319140>\
**Category:** programming\
**Created:** [February 10, 2011, 3:01am UTC](https://forum.kirupa.com/t/i-need-help-with-writing-a-php-conditional-statement/319140 "2011-02-10T03:01:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lilymc](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/lilymc/32/3676_2.png) [@lilymc](https://forum.kirupa.com/u/lilymc)\
**Post date:** [February 10, 2011, 3:01am UTC](https://forum.kirupa.com/t/i-need-help-with-writing-a-php-conditional-statement/319140/1 "2011-02-10T03:01:09Z")

</div>

I don’t know PHP, but my site is using the thematic framework powered by wordpress, and the pages are PHP.

All I’m trying to do is use a different wrapper background for the home (start) page, than all the other pages.

What I originally thought I could do is just create a new wrapper div just for the home page, but with the set-up I have now, I don’t even know where to hard code that… the “wrapper” div is not in the header.php, at least I didn’t see it. And when I tried to add a unique wrapper div to the start page php it messed things up.

I _was_ able to do a conditional statement for the repeating body background (thanks to google) but so far I haven’t been able to do that for the wrapper background.

Here’s what I have for the body background:

```php
<body id="
<?php if (is_page_template('start.php')){
       echo "home-bg";} 

else{
echo "default";
}?>" >

```

and the css:

> body#default { background:url(/images/pages-repeating-bg.png) top repeat-x #00040e; }  
> body#home-bg { background:url(/images/repeating-bg-2-5.png) top repeat-x #00040e;}

I’m even willing to pay someone for their time (this would probably take someone who knows PHP like 5 minutes to figure out) because my site is finished and I was really hoping to put it up today, but now I just want to change the background to make it smaller on all but the home page. Any help would be SO appreciated! 🙂

thanks!!
