Base_Tag()
Elementor base tag.
Description
An abstract class to register new Elementor tags.
Changelog
Version | Description |
---|---|
2.0.0 | Introduced. |
Methods
- get_categories — Base_Tag::get_categories() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php abstract public function get_categories(); Used By core/dynamic-tags/base-tag.php: Base_Tag::get_editor_config()
- get_content — Base_Tag::get_content( array $options = array() ) Parameters Parameters Name Type Required Description $options array Optional Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php * @since 2.0.0
- get_content_type — Base_Tag::get_content_type() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php */ Used By core/dynamic-tags/base-tag.php: Base_Tag::get_editor_config()
- get_editor_config — Base_Tag::get_editor_config() Source core/dynamic-tags/base-tag.php public function get_editor_config() { ob_start(); $this->print_panel_template(); $panel_template = ob_get_clean(); return [ 'name' => $this->get_name(), 'title' => $this->get_title(), 'panel_template' => $panel_template, 'categories' => $this->get_categories(), 'group' => $this->get_group(), 'controls' => $this->get_controls(), 'content_type' => $this->get_content_type(), 'settings_required' => $this->is_settings_required(), ]; } Uses core/dynamic-tags/base-tag.php: Base_Tag::is_settings_required() core/dynamic-tags/base-tag.php: Base_Tag::get_content_type() core/dynamic-tags/base-tag.php: Base_Tag::get_group() core/dynamic-tags/base-tag.php: Base_Tag::get_categories() core/dynamic-tags/base-tag.php: Base_Tag::get_title() core/dynamic-tags/base-tag.php: Base_Tag::print_panel_template() Show 1 […]
- get_group — Base_Tag::get_group() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php return 'tag'; Used By core/dynamic-tags/base-tag.php: Base_Tag::get_editor_config()
- get_panel_template_setting_key — Base_Tag::get_panel_template_setting_key() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php abstract public function get_categories(); /** Used By core/dynamic-tags/base-tag.php: Base_Tag::print_panel_template()
- get_title — Base_Tag::get_title() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php /** Used By core/dynamic-tags/base-tag.php: Base_Tag::get_editor_config()
- get_type — Base_Tag::get_type() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php final public static function get_type() { return 'tag'; }
- get_unique_name — Base_Tag::get_unique_name() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php /** * @since 2.0.0 * @access public Used By core/dynamic-tags/base-tag.php: Base_Tag::init_controls()
- init_controls — Base_Tag::init_controls() Changelog Changelog Version Description 2.0.0 Introduced. Source core/dynamic-tags/base-tag.php } /** * @since 2.0.0 * @access public */ public function print_panel_template() { $panel_template_setting_key = $this->get_panel_template_setting_key(); if ( ! $panel_template_setting_key ) { return; } ?><# var key = <?php echo esc_html( $panel_template_setting_key ); ?>; if ( key ) { var settingsKey = "<?php echo esc_html( $panel_template_setting_key […]
Source
core/dynamic-tags/base-tag.php
/** * Elementor base tag. * * An abstract class to register new Elementor tags. * * @since 2.0.0 * @abstract */ abstract class Base_Tag extends Controls_Stack { /** * @since 2.0.0 * @access public * @static */ final public static function get_type() { return 'tag'; } /** * @since 2.0.0 * @access public * @abstract */ abstract public function get_categories(); /** * @since 2.0.0 * @access public * @abstract */ abstract public function get_group(); /** * @since 2.0.0 * @access public * @abstract */ abstract public function get_title(); /** * @since 2.0.0 * @access public * @abstract */ abstract public function get_content( array $options = [] ); /** * @since 2.0.0 * @access public * @abstract */ abstract public function get_content_type(); /** * @since 2.0.0 * @access public */ public function get_panel_template_setting_key() { return ''; } /** * @since 2.0.0 * @access public */ public function is_settings_required() { return false; } /** * @since 2.0.0 * @access public */ public function print_panel_template() { $panel_template_setting_key = $this->get_panel_template_setting_key(); if ( ! $panel_template_setting_key ) { return; } ?><# var key = <?php echo esc_html( $panel_template_setting_key ); ?>; if ( key ) { var settingsKey = "<?php echo esc_html( $panel_template_setting_key ); ?>"; /*