diff --git a/e107_plugins/hero/hero_setup.php b/e107_plugins/hero/hero_setup.php index aadfd2e13..0ae3a7a47 100644 --- a/e107_plugins/hero/hero_setup.php +++ b/e107_plugins/hero/hero_setup.php @@ -28,6 +28,11 @@ if(!class_exists("hero_setup")) */ function install_post($var) { + if(!e107::getDb()->isEmpty('hero')) + { + return null; + } + $ret = e107::getXml(true)->e107Import(e_PLUGIN."hero/xml/install.xml"); if(!empty($ret['success'])) diff --git a/e107_plugins/hero/hero_shortcodes.php b/e107_plugins/hero/hero_shortcodes.php index ac831f39c..7df05fba2 100644 --- a/e107_plugins/hero/hero_shortcodes.php +++ b/e107_plugins/hero/hero_shortcodes.php @@ -7,7 +7,7 @@ if (!defined('e107_INIT')) { exit; } class plugin_hero_hero_shortcodes extends e_shortcode { - public $count =0; + public $count = 0; /** * {hero_ID} @@ -66,22 +66,34 @@ class plugin_hero_hero_shortcodes extends e_shortcode return "(No Slides Found)"; // debug info } - $text = ''; + if(defset('BOOTSTRAP') === 5) + { + $start = ''; + } + else + { + $start = ''; + } - return $text; + return $start.$text.$end; } @@ -142,7 +154,7 @@ class plugin_hero_hero_shortcodes extends e_shortcode public function sc_hero_text() { - $count = (int) $this->count; + $count = $this->count; return e107::getParser()->toHTML($this->var['hero_bullets'][$count]['text'],true,'BODY'); } @@ -244,12 +256,12 @@ class plugin_hero_hero_shortcodes extends e_shortcode return null; } - return e107::getParser()->parseTemplate($this->var['hero_button1']['label'], true); + return e107::getParser()->parseTemplate($this->var['hero_button1']['label']); } public function sc_hero_button1_url($parm=null) { - return e107::getParser()->parseTemplate($this->var['hero_button1']['url'], true); + return e107::getParser()->parseTemplate($this->var['hero_button1']['url']); } public function sc_hero_button1_class($parm=null) @@ -274,12 +286,12 @@ class plugin_hero_hero_shortcodes extends e_shortcode public function sc_hero_button2_label($parm=null) { - return e107::getParser()->parseTemplate($this->var['hero_button2']['label'], true); + return e107::getParser()->parseTemplate($this->var['hero_button2']['label']); } public function sc_hero_button2_url($parm=null) { - return e107::getParser()->parseTemplate($this->var['hero_button2']['url'], true); + return e107::getParser()->parseTemplate($this->var['hero_button2']['url']); } public function sc_hero_button2_class($parm=null)