Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Productlist Pager geht nicht
 
Sorato
Jr. Member
 
Total Posts:  5
Joined:  2013-03-07
 

Hallo zusammen,

Ich hab eine Extension erstellt die eine Produktliste darstellt. Das Anzeigen der Produktliste funktioniert gut.
Aber es werden keine Seiten angezeigt.

Hier die Layout XML:

<reference name="content">
            <
block type="core/template" name="yearmakemodel" template="toowoxx/yearmakemodel/index.phtml">
                <
block type="yearmakemodel/list" name="product_list" template="catalog/product/list.phtml">
                    <
block type="catalog/product_list_toolbar" name="product_list_toolbar"
                           
template="catalog/product/list/toolbar.phtml">
                        <
block type="page/html_pager" name="product_list_toolbar_pager" />
                    </
block>
                </
block>
            </
block>
        </
reference>

Und hier der Code um den HTML Teil des Blocks zu bekommen:

private function getBlockHTML($skulist)
    
{
        $collection 
Mage::getModel('catalog/product')->getCollection();
        
$collection->addAttributeToFilter('sku', array('in'$skulist));
        
$collection->addAttributeToSelect('*');
        
Mage::unregister("toowoxx_ymm_products");
        
Mage::register("toowoxx_ymm_products"$collection);
        
$ymm_block $this->getLayout()->getBlock("product_list");
        
$ymm_block->getChild("product_list_toolbar")->setCollection($collection);
        return 
$ymm_block->toHtml();
    
}

Ich hoffe es kann mir jemand helfen.

Viele Grüße
Markus

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top