title: In Wordpress I want my sidebar to change based on the page
body: <p>Ok I just developed my first custom Wordpress theme using a guide - I'm still a noob. I'm not using widgets to fill the sidebar, I want to fill it myself with my own code and images.</p>
  
  <p>So lets say I want the first sidebar I made to show up only on the homepage, and then the 2nd sidebar I made to show up on every other page. Can I use an if statement?</p>
  
  <pre><code>&lt;?php
  
  if(is_home()){
  
  echo
  
  "&lt;div class="row"&gt;
              &lt;div class="span3"&gt;
                  &lt;div id="search-box"&gt;&lt;img id="search_text" src="http://localhost/Dorsa/wp-content/themes/Bootstrap/img/text_findyourhome.png"&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
  
          &lt;div class="row"&gt;
              &lt;div class="span3"&gt;
                  &lt;img class="box_shadow" src="http://localhost/Dorsa/wp-content/themes/Bootstrap/img/box-shadow.png" style="padding-left:0;"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="row"&gt;
              &lt;div class="span3"&gt;&lt;div id="news" style="margin-top:275px;margin-bottom:200px"&gt;News&lt;/div&gt;&lt;/div&gt;
           &lt;/div&gt;"
           }
  
           else
           {
           echo
           "sidebar 2 code - didn't write it yet"
           }       
  ?&gt;
  </code></pre>