当前位置: 首页>>代码示例>>PHP>>正文


PHP Mage_Core_Block_Template::_toHtml方法代码示例

本文整理汇总了PHP中Mage_Core_Block_Template::_toHtml方法的典型用法代码示例。如果您正苦于以下问题:PHP Mage_Core_Block_Template::_toHtml方法的具体用法?PHP Mage_Core_Block_Template::_toHtml怎么用?PHP Mage_Core_Block_Template::_toHtml使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Mage_Core_Block_Template的用法示例。


在下文中一共展示了Mage_Core_Block_Template::_toHtml方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: _toHtml

 /**
  * Generate and return the ShareThis JS
  *
  * @return string
  */
 protected function _toHtml()
 {
     $helper = Mage::helper('wp_addon_addthis');
     if ($helper->isActiveOnPage()) {
         $config = array('data_track_clickback' => (bool) $helper->getOption('addthis_append_data'), 'ui_atversion' => $helper->getVersion(), 'ui_header_background' => $helper->getOption('addthis_header_background'), 'ui_header_color' => $helper->getOption('addthis_header_color'), 'ui_cobrand' => $helper->getOption('addthis_brand'), 'ui_508_compliant' => (bool) $helper->getOption('addthis_508'), 'data_track_addressbar' => (bool) $helper->getOption('data_track_addressbar'), 'data_track_textcopy' => (bool) $helper->getOption('addthis_copytracking2'));
         if ($helper->getOption('data_ga_property')) {
             $config['data_ga_property'] = $helper->getOption('data_ga_property');
             $config['data_ga_social'] = true;
         }
         if ($helper->getOption('addthis_language') == '2') {
             $config['ui_language'] = $helper->getOption('addthis_language');
         }
         $share = array();
         if ($helper->getOption('addthis_twitter_template')) {
             $share['passthrough']['twitter']['via'] = $this->_getFirstTwitterUsername($helper->getOption('addthis_twitter_template'));
         }
         if ($helper->getOption('addthis_bitly_login') && $helper->getOption('addthis_bitly_key')) {
             $share['url_transforms']['shorten']['twitter'] = 'bitly';
             $share['shorteners']['bitly']['login'] = $helper->getOption('addthis_bitly_login');
             $share['shorteners']['bitly']['apiKey'] = $helper->getOption('addthis_bitly_key');
         }
         return implode('', array('<script type="text/javascript">var addthis_product = \'wpp-3.1\';', $this->_mergeArrayJson($config, $helper->getOption('addthis_config_json'), "var addthis_config = '%s';"), sprintf("var addthis_options = '%s';", $helper->getOption('addthis_options')), $this->_mergeArrayJson($share, $helper->getOption('addthis_share_json'), "if (typeof(addthis_share) == \"undefined\"){ addthis_share = '%s';}"), '</script>', sprintf('<script type="text/javascript" src="//s7.addthis.com/js/%s/addthis_widget.js#pubid=%s"></script>', $helper->getVersion(), $this->getPublisherId())));
     }
     return parent::_toHtml();
 }
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:30,代码来源:Js.php

示例2: _toHtml

 protected function _toHtml()
 {
     if (!$this->_canShow()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:AleksNesh,项目名称:pandora,代码行数:7,代码来源:Abstract.php

示例3: _toHtml

 protected function _toHtml()
 {
     if (!(bool) Mage::getStoreConfig('specialproducts/general/active')) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:SuperAssassinNinja,项目名称:romances,代码行数:7,代码来源:Specialproducts.php

示例4: _toHtml

 /**
  * Render block HTML
  *
  * @return string
  */
 protected function _toHtml()
 {
     if (!$this->getCanUseToken()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:MadMaxAi,项目名称:sage-pay-suite-ce,代码行数:12,代码来源:TokenList.php

示例5: _toHtml

 protected function _toHtml()
 {
     if (!Mage::getStoreConfig('ves_base/general_setting/show')) {
         return;
     }
     return parent::_toHtml();
 }
开发者ID:booklein,项目名称:bookle,代码行数:7,代码来源:Sitelogo.php

示例6: _toHtml

 public function _toHtml()
 {
     if (Mage::getStoreConfigFlag('payment/paypaluk_express/active') && Mage::getSingleton('checkout/session')->getQuote()->validateMinimumAmount()) {
         return parent::_toHtml();
     }
     return '';
 }
开发者ID:HelioFreitas,项目名称:magento-pt_br,代码行数:7,代码来源:Shortcut.php

示例7: _toHtml

 protected function _toHtml()
 {
     if ($this->getTestimonials()) {
         return parent::_toHtml();
     }
     return '';
 }
开发者ID:masterdef,项目名称:testimonials,代码行数:7,代码来源:List.php

示例8: _toHtml

 /**
  * Render HTML for the page type if the module is enabled for the current
  * store.
  *
  * @return string
  */
 protected function _toHtml()
 {
     if (!Mage::helper('nosto_tagging')->isModuleEnabled() || !Mage::helper('nosto_tagging/account')->existsAndIsConnected()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:nosto,项目名称:nosto-magento-extension,代码行数:13,代码来源:Pagetype.php

示例9: _toHtml

 protected function _toHtml()
 {
     if (!$this->helper('inchoo_piwik')->isModuleOutputEnabled()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:renatofig,项目名称:Inchoo_Piwik,代码行数:7,代码来源:Page.php

示例10: _toHtml

 public function _toHtml()
 {
     if (!(bool) Mage::getStoreConfig('manufacturer/general/enable')) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:SuperAssassinNinja,项目名称:romances,代码行数:7,代码来源:ManufacturerInfo.php

示例11: _toHtml

 protected function _toHtml()
 {
     if (!Mage::getStoreConfig('catalog/aitcg/aitcg_use_social_networks_sharing')) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:Eximagen,项目名称:BulletMagento,代码行数:7,代码来源:Socialbuttons.php

示例12: _toHtml

 protected function _toHtml()
 {
     /*if ($toolbar = $this->getChild('toolbar')) {
           $toolbar->setCollection($this->getValuesCollection());
       }*/
     return parent::_toHtml();
 }
开发者ID:arzzzen,项目名称:DC_Catalog,代码行数:7,代码来源:All.php

示例13: _toHtml

 protected function _toHtml()
 {
     if (!$this->helper('bestseller')->getIsActive()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:kanotest15,项目名称:cbmagento,代码行数:7,代码来源:Bestseller.php

示例14: _toHtml

 /**
  * Render block
  *
  * @return string
  */
 protected function _toHtml()
 {
     if (Mage::helper('enterprise_wishlist')->isMultipleEnabled()) {
         return parent::_toHtml();
     }
     return '';
 }
开发者ID:hyhoocchan,项目名称:mage-local,代码行数:12,代码来源:Management.php

示例15: _toHtml

 public function _toHtml()
 {
     if (!Mage::getSingleton('helpdesk/config')->getSatisfactionIsActive()) {
         return '';
     }
     return parent::_toHtml();
 }
开发者ID:cesarfelip3,项目名称:clevermage_new,代码行数:7,代码来源:Satisfaction.php


注:本文中的Mage_Core_Block_Template::_toHtml方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。