title: WordPress functions.php Problem
body: <p>Can a function inside the functions.php file call another function from within functions.php? I'm guessing yes and which is why I wrote the code below, but it doesn't work for some reason. Can anyone please check it out and help me.</p>
  
  <p>I tried calling pageBarColor() from register_sidebar()</p>
  
  <p>Thanks.</p>
  
  <pre><code>&lt;?php
  if (function_exists('register_sidebar')) {
    register_sidebar(array(
     'before_widget' =&gt; '&lt;li class="sidebarModule"&gt;',
     'after_widget' =&gt; '&lt;/li&gt;&lt;!-- end module --&gt;',
     'before_title' =&gt; '&lt;h2 class="moduleTitle '.pageBarColor().'"&gt;',
     'after_title' =&gt; '&lt;/h2&gt;',
    ));
  }
  
  function pageBarColor(){
      if(is_category('3')) {
          return "color1";
      } elseif(is_category('4')) {
          return "color2";
      } elseif(is_category('5')) {
          return "color3";
      } elseif(is_category('6')) {
          return "color4";
      } elseif(is_category('7')) {
          return "color5";
      }
  }
  ?&gt;
  </code></pre>