/** * Class constructor * * @param string $name * * @access public */ public function __construct($name) { parent::__construct($name); $css_path = FileSystem::getDirectory('fonts_path') . 'fontello.css'; $items = SectionAbstract::flipSourceData(MetaBox::getFontelloIcons('icon', $css_path, 'silverwp_fontello_icons')); $this->setOptions($items); }
public function __construct($name) { parent::__construct($name); //add fontello icons $icons = MetaBox::getFontelloIcons(); $this->setOptions($icons); }
/** * * Class constructor * * @param string $name * * @throws \SilverWp\Helper\Control\Exception */ public function __construct($name) { parent::__construct($name); //add fontello icons $css_uri = FileSystem::getDirectory('fonts_uri') . 'fontello.css'; $items = MetaBox::getFontelloIcons('icon', $css_uri, 'silverwp_fontello_icons'); $this->setOptions($items); }
/** * * Check the current post or page have a sidebar * * @static * @access public * @return boolean */ public static function isDisplayed() { //fix Ticket #220 if (is_search() && is_home() || is_tag() || is_date() || is_archive()) { $post_id = Option::get_option('page_for_posts'); $post_type = 'page'; } else { $page_object = get_queried_object(); $post_id = get_queried_object_id(); $post_type = isset($page_object->post_type) ? $page_object->post_type : 'posts'; } $sidebar = MetaBox::isSidebar($post_type, $post_id); if ((is_search() || is_author() || is_tag() || is_date() || is_archive()) && Option::get_theme_option('blogposts_sidebar') != '0') { $sidebar = true; } $display = apply_filters('sage/display_sidebar', $sidebar); return $display; }