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

Replace content inside tab
 
ElectricAvenue
Jr. Member
 
Avatar
Total Posts:  20
Joined:  2012-02-01
 

I have 2 custom blocks that display custom inside tabs content by static blocks.

I would like to replace one of them and display accessories.

The question is, how to put

<?php echo $this->getChildHtml('accessories_products');?>

Inside:

<?php // Creating some extra tabs: add static CMS blocks as tabs
    
$_extraTabs '';
    
$_extraPanes '';
    
$_tmpBlock Mage::getModel('cms/block')
        ->
setStoreId(Mage::app()->getStore()->getId())
        ->
load('block_product_custom_tab1');
    if(
$_tmpBlock->getIsActive()) {
        $_extraTabs 
.= '<a href="#" class=""><span>' $_tmpBlock->getTitle() . '</span></a>';
        
$_extraPanes .= '<div class="pane product-tabs-content"><div class="std">' $_tmpBlock->getContent() . '</div></div>';  
    
}
    $_tmpBlock 
Mage::getModel('cms/block')
        ->
setStoreId(Mage::app()->getStore()->getId())
        ->
load('block_product_custom_tab2');
    if(
$_tmpBlock->getIsActive()) {
        $_extraTabs 
.= '<a href="#" class=""><span>' $_tmpBlock->getTitle() . '</span></a>';
        
$_extraPanes .= '<div class="pane product-tabs-content"><div class="std">' $_tmpBlock->getContent() . '</div></div>';
    
}
?>
thanks
 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top