My current code:
$collection = Mage::getModel('catalog/product')->getCollection();
$collection->setOrder('id', 'ASC');
$collection->addAttributeToSelect('*');
$collection->addAttributeToFilter('status', '1');
$collection->addAttributeToFilter('type_id', array('neq' => 'bundle'));
$collection->addAttributeToFilter('type_id', array('neq' => 'configurable'));
$collection->addAttributeToFilter('type_id', array('neq' => 'grouped'));
The problem is that I still get the child products of configurable products where the parent is disabled or not assigned to any category. So I get the child product but it is not available in the webshop.
How can I filter the attributes of the parent products?