isActive(); $tp = Mage::app()->getRequest()->getParam('tp'); $accessCode = Mage::app()->getRequest()->getParam('code'); $dbAccessCode = $helper->getConfig('code'); if(!empty($dbAccessCode)){ $checkAccessCode = ($dbAccessCode == $accessCode) ? true : false; }else{ $checkAccessCode = true; } if ($tp && $isActive && $checkAccessCode): /* @var $block Mage_Core_Block_Abstract */ $block = $observer->getBlock(); $transport = $observer->getTransport(); $fileName = $block->getTemplateFile(); $thisClass = get_class($block); if($fileName){ $preHtml = '
'.$fileName.'
'; $preHtml .= '
'.$thisClass.'
'; $postHtml = '
'; }else{ $preHtml = null; $postHtml = null; } $html = $transport->getHtml(); $html = $preHtml . $html . $postHtml; $transport->setHtml($html); endif; } }