title: Why are products in the category with Mage::app('default') but not with Mage::app('admin')?
body: <p>I wrote an extension and in this extension I need the count of active products of a category. </p>
  
  <p>I used this snipped to determine active products by category: </p>
  
  <pre><code> $return = Mage::getModel('catalog/category')
          -&gt;load($category-&gt;getId())
          -&gt;getProductCollection()
          -&gt;addAttributeToSelect('entity_id')
          -&gt;addAttributeToFilter('status', Mage_Catalog_Model_Product_Status::STATUS_ENABLED)
          -&gt;addAttributeToFilter('visibility', Mage_Catalog_Model_Product_Visibility::VISIBILITY_BOTH)
          -&gt;count();
  </code></pre>
  
  <p>If I call the function to get the count of active products in my test.php </p>
  
  <pre><code>header('Content-Type: text/html; charset=utf-8');
  require_once "app/Mage.php";
  Mage::reset();
  Mage::app('default');
  
  var_dump(myDummyFunction($categoryObject));
  </code></pre>
  
  <p>I get 3 as the result. If I use the same function within the same magento in the extension (which is used in the admin area) the result is 0. </p>
  
  <p>Has somebody an idea why this happens and how to fix this?</p>
  
  <p>Btw: If I change the Mage::app('default'); in the test.php to Mage::app('admin'); it also displays 0... </p>