/** * Contructor */ public function __construct($attributes = array()) { parent::__construct($attributes); if (!Mage::getStoreConfig('ves_blog/general_setting/show')) { return; } $my_template = ""; if (isset($attributes['template']) && $attributes['template']) { $my_template = $attributes['template']; } elseif ($this->hasData("template")) { $my_template = $this->getData("template"); } else { $my_template = "ves/blog/block/archives.phtml"; } $this->setTemplate($my_template); $enable_cache = $this->getConfig("enable_cache", 1); if (!$enable_cache) { $cache_lifetime = null; } else { $cache_lifetime = $this->getConfig("cache_lifetime", 86400); $cache_lifetime = (int) $cache_lifetime > 0 ? $cache_lifetime : 86400; } $this->addData(array('cache_lifetime' => $cache_lifetime)); $this->addCacheTag(array(Mage_Core_Model_Store::CACHE_TAG, Mage_Cms_Model_Block::CACHE_TAG, Ves_Blog_Model_Config::CACHE_BLOCK_ARCHIVES_TAG)); }
/** * Contructor */ public function __construct($attributes = array()) { parent::__construct($attributes); $my_template = ""; if (isset($attributes['template']) && $attributes['template']) { $my_template = $attributes['template']; } elseif ($this->hasData("template")) { $my_template = $this->getData("template"); } else { $my_template = "ves/blog/block/latest.phtml"; } $this->setTemplate($my_template); }
/** * Contructor */ public function __construct($attributes = array()) { parent::__construct($attributes); if (!Mage::getStoreConfig('ves_blog/general_setting/show')) { return; } $my_template = ""; if (isset($attributes['template']) && $attributes['template']) { $my_template = $attributes['template']; } elseif ($this->hasData("template")) { $my_template = $this->getData("template"); } else { $my_template = "ves/blog/block/search.phtml"; } $this->setTemplate($my_template); }
/** * Contructor */ public function __construct($attributes = array()) { $this->setTemplate("ves/blog/block/widget/latest.phtml"); parent::__construct($attributes); }
/** * Contructor */ public function __construct($attributes = array()) { $this->setTemplate("ves/blog/block/cmenu.phtml"); Mage::helper('ves_blog/media')->addMediaFile("js", "ves_blog/menu.js"); parent::__construct($attributes); }
/** * Contructor */ public function __construct($attributes = array()) { //die("AAAAAAAAA"); parent::__construct($attributes); $this->setTemplate("ves/blog/block/lcomment.phtml"); }