Gestionnaire de fichiers - Editer - /home/wwgoat/public_html/blog/wp-content/plugins/foxiz-core/elementor/hierarchical-2.php
Arrière
<?php namespace foxizElementor\Widgets; use Elementor\Widget_Base; use Elementor\Controls_Manager; use foxizElementorControl\Options; if ( ! defined( 'ABSPATH' ) ) { exit; } /** * Class Hierarchical_2 * @package foxizElementor\Widgets */ class Hierarchical_2 extends Widget_Base { public function get_name() { return 'foxiz-hierarchical-2'; } public function get_title() { return esc_html__( 'Foxiz - Hierarchical 2', 'foxiz-core' ); } public function get_icon() { return 'eicon-favorite'; } public function get_categories() { return array( 'foxiz' ); } protected function register_controls() { $this->start_controls_section( 'query_filters', array( 'label' => esc_html__( 'Query Settings', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_CONTENT, ) ); if ( 'rb-etemplate' === get_post_type() ) { $this->add_control( 'dynamic_query_info', array( 'type' => Controls_Manager::RAW_HTML, 'raw' => Options::dynamic_query_info(), 'content_classes' => 'elementor-panel-alert elementor-panel-alert-success', ) ); $this->add_control( 'dynamic_query_category_info', array( 'type' => Controls_Manager::RAW_HTML, 'raw' => Options::dynamic_query_category_info(), 'content_classes' => 'elementor-panel-alert elementor-panel-alert-warning', ) ); $this->add_control( 'category', array( 'label' => esc_html__( 'Category Filter', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::category_description(), 'options' => Options::cat_dropdown( true ), 'default' => '0', ) ); } else { $this->add_control( 'category', array( 'label' => esc_html__( 'Category Filter', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::category_description(), 'options' => Options::cat_dropdown(), 'default' => '0', ) ); } $this->add_control( 'categories', array( 'label' => esc_html__( 'Categories Filter', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => Options::categories_description(), 'default' => '', ) ); $this->add_control( 'tags', array( 'label' => esc_html__( 'Tags Slug Filter', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => Options::tags_description(), 'default' => '', ) ); $this->add_control( 'tag_not_in', array( 'label' => esc_html__( 'Exclude Tags Slug', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => Options::tag_not_in_description(), 'default' => '', ) ); $this->add_control( 'format', array( 'label' => esc_html__( 'Post Format', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::format_description(), 'options' => Options::format_dropdown(), 'default' => '0', ) ); $this->add_control( 'author', array( 'label' => esc_html__( 'Author Filter', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::author_description(), 'options' => Options::author_dropdown(), 'default' => '0', ) ); $this->add_control( 'post_not_in', array( 'label' => esc_html__( 'Exclude Post IDs', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => Options::post_not_in_description(), 'default' => '', ) ); $this->add_control( 'post_in', array( 'label' => esc_html__( 'Post IDs Filter', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => Options::post_in_description(), 'default' => '', ) ); $this->add_control( 'order', array( 'label' => esc_html__( 'Sort Order', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::order_description(), 'options' => Options::order_dropdown(), 'default' => 'date_post', ) ); $this->add_control( 'posts_per_page', array( 'label' => esc_html__( 'Number of Posts', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::posts_per_page_description(), 'default' => '5', ) ); $this->add_control( 'offset', array( 'label' => esc_html__( 'Post Offset', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::offset_description(), 'default' => '', ) ); $this->end_controls_section(); $this->start_controls_section( 'block_pagination', array( 'label' => esc_html__( 'Ajax Pagination', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_CONTENT, ) ); $this->add_control( 'pagination', array( 'label' => esc_html__( 'Pagination Type', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::pagination_description(), 'options' => Options::pagination_dropdown( array( 'load_more', 'infinite_scroll' ) ), 'default' => '0', ) ); $this->end_controls_section(); $this->start_controls_section( 'unique_section', array( 'label' => esc_html__( 'Unique Post', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_CONTENT, ) ); $this->add_control( 'unique', array( 'label' => esc_html__( 'Unique Post', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::unique_description(), 'options' => Options::switch_dropdown( false ), 'default' => '-1', ) ); $this->end_controls_section(); $this->start_controls_section( 'block_design', array( 'label' => esc_html__( 'Block Design', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_STYLE, ) ); $this->add_control( 'layout_info', array( 'type' => Controls_Manager::RAW_HTML, 'raw' => esc_html__( 'This layout is best suited for putting to the column from 25% to 50% of the width.', 'foxiz-core' ), 'content_classes' => 'elementor-panel-alert elementor-panel-alert-success', ) ); $this->add_control( 'entry_category', array( 'label' => esc_html__( 'Entry Category', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::entry_category_description(), 'options' => Options::extended_entry_category_dropdown( false ), 'default' => '-1', ) ); $this->add_control( 'entry_meta', array( 'label' => esc_html__( 'Entry Meta Tags', 'foxiz-core' ), 'type' => Controls_Manager::TEXTAREA, 'rows' => 2, 'description' => Options::entry_meta_tags_description(), 'options' => Options::entry_meta_tags_dropdown(), 'placeholder' => Options::entry_meta_tags_placeholder(), 'default' => 'avatar, author, date' ) ); $this->add_control( 'review', array( 'label' => esc_html__( 'Review Meta', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::review_description(), 'options' => Options::review_dropdown( false ), 'default' => 'replace', ) ); $this->add_control( 'review_meta', array( 'label' => esc_html__( 'Review Meta Description', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::review_meta_description(), 'options' => Options::switch_dropdown( false ), 'default' => '1', ) ); $this->add_control( 'bookmark', array( 'label' => esc_html__( 'Bookmark Icon', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::bookmark_description(), 'options' => Options::switch_dropdown( false ), 'default' => '-1', ) ); $this->add_control( 'excerpt_length', array( 'label' => esc_html__( 'Excerpt - Max Length', 'foxiz-core' ), 'type' => Controls_Manager::TEXT, 'description' => esc_html__( 'Leave this option blank or set 0 to disable.', 'foxiz-core' ), 'default' => '', ) ); $this->add_control( 'excerpt_source', array( 'label' => esc_html__( 'Excerpt - Source', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::excerpt_source_description(), 'options' => Options::excerpt_source_dropdown(), 'default' => '0', ) ); $this->add_control( 'readmore', array( 'label' => esc_html__( 'Read More Button', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::readmore_description(), 'options' => Options::switch_dropdown( false ), 'default' => '-1', ) ); $this->add_control( 'sponsor_meta', array( 'label' => esc_html__( 'Sponsored Meta', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::sponsor_meta_description(), 'options' => Options::sponsor_dropdown( false ), 'default' => '1', ) ); $this->add_control( 'title_tag', array( 'label' => esc_html__( 'Title HTML Tag', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::heading_html_description(), 'options' => Options::heading_html_dropdown( esc_html__( '- Default -', 'foxiz-core' ) ), 'default' => '0', ) ); $this->add_control( 'sub_title_tag', array( 'label' => esc_html__( 'Secondary Title HTML Tag', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::sub_heading_html_description(), 'options' => Options::heading_html_dropdown( esc_html__( '- Default -', 'foxiz-core' ) ), 'default' => '0', ) ); $this->end_controls_section(); $this->start_controls_section( 'font_size_section', array( 'label' => esc_html__( 'Custom Font Size', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_STYLE, ) ); $this->add_responsive_control( 'entry_category_size', array( 'label' => esc_html__( 'Entry Category Size', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::entry_category_size_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .p-category' => 'font-size: {{VALUE}}px !important;' ), ) ); $this->add_responsive_control( 'title_tag_size', array( 'label' => esc_html__( 'Title Font Size', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::title_size_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .entry-title' => 'font-size: {{VALUE}}px;' ), ) ); $this->add_responsive_control( 'sub_title_tag_size', array( 'label' => esc_html__( 'Secondary Title Font Size', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::sub_title_size_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .p-list-inline > .entry-title' => 'font-size: {{VALUE}}px;' ), ) ); $this->add_responsive_control( 'entry_format_size', array( 'label' => esc_html__( 'Entry Format Size', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::entry_format_size_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .p-format' => 'font-size: {{VALUE}}px !important;' ), ) ); $this->add_responsive_control( 'entry_excerpt_size', array( 'label' => esc_html__( 'Entry Excerpt Size', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::excerpt_size_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .entry-summary' => 'font-size: {{VALUE}}px;' ), ) ); $this->end_controls_section(); $this->start_controls_section( 'mobile_meta_section', array( 'label' => esc_html__( 'Responsive - Hide Elements', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_STYLE, ) ); $this->add_control( 'hide_category', array( 'label' => esc_html__( 'Hide Entry Category', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::hide_category_description(), 'options' => Options::hide_dropdown( false ), 'default' => '0', ) ); $this->add_control( 'tablet_hide_meta', array( 'label' => esc_html__( 'Tablet - Hide Entry Meta', 'foxiz-core' ), 'type' => Controls_Manager::TEXTAREA, 'rows' => 2, 'description' => Options::tablet_hide_meta_description(), 'options' => Options::entry_meta_tags_dropdown(), 'placeholder' => esc_html__( 'avatar, author', 'foxiz-core' ), 'multiple' => true, 'default' => array() ) ); $this->add_control( 'mobile_hide_meta', array( 'label' => esc_html__( 'Mobile - Hide Entry Meta', 'foxiz-core' ), 'type' => Controls_Manager::TEXTAREA, 'rows' => 2, 'description' => Options::mobile_hide_meta_description(), 'options' => Options::entry_meta_tags_dropdown(), 'placeholder' => esc_html__( 'avatar, author', 'foxiz-core' ), 'multiple' => true, 'default' => array() ) ); $this->add_control( 'hide_excerpt', array( 'label' => esc_html__( 'Hide Excerpt', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::hide_excerpt_description(), 'options' => Options::hide_dropdown( false ), 'default' => '0', ) ); $this->end_controls_section(); $this->start_controls_section( 'color_section', array( 'label' => esc_html__( 'Text Color Scheme', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_STYLE, ) ); $this->add_control( 'color_scheme_info', array( 'type' => Controls_Manager::RAW_HTML, 'raw' => Options::color_scheme_info_description(), 'content_classes' => 'elementor-panel-alert elementor-panel-alert-success', ) ); $this->add_control( 'color_scheme', array( 'label' => esc_html__( 'Text Color Scheme', 'foxiz-core' ), 'type' => Controls_Manager::SELECT, 'description' => Options::color_scheme_description(), 'options' => array( '0' => esc_html__( 'Default (Dark Text)', 'foxiz-core' ), '1' => esc_html__( 'Light Text', 'foxiz-core' ) ), 'default' => '0', ) ); $this->end_controls_section(); $this->start_controls_section( 'font_section', array( 'label' => esc_html__( 'Custom Font', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_STYLE, ) ); $this->add_control( 'custom_font_info', array( 'type' => Controls_Manager::RAW_HTML, 'raw' => Options::custom_font_info_description(), 'content_classes' => 'elementor-panel-alert elementor-panel-alert-success', ) ); $this->add_group_control( \Elementor\Group_Control_Typography::get_type(), array( 'label' => esc_html__( 'Post Title Font', 'foxiz-core' ), 'name' => 'title_font', 'selector' => '{{WRAPPER}} .entry-title', ) ); $this->add_group_control( \Elementor\Group_Control_Typography::get_type(), array( 'label' => esc_html__( 'Secondary Post Title Font', 'foxiz-core' ), 'name' => 'sub_title_font', 'selector' => '{{WRAPPER}} .p-list-inline > .entry-title', ) ); $this->add_group_control( \Elementor\Group_Control_Typography::get_type(), array( 'label' => esc_html__( 'Entry Category Font', 'foxiz-core' ), 'name' => 'category_font', 'selector' => '{{WRAPPER}} .p-categories', ) ); $this->end_controls_section(); $this->start_controls_section( 'spacing_section', array( 'label' => esc_html__( 'Spacing', 'foxiz-core' ), 'tab' => Controls_Manager::TAB_LAYOUT, ) ); $this->add_responsive_control( 'el_spacing', array( 'label' => esc_html__( 'Custom Element Spacing', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::el_spacing_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .p-wrap' => '--el-spacing: {{VALUE}}px;' ), ) ); $this->add_responsive_control( 'bottom_margin', array( 'label' => esc_html__( 'Custom Bottom Margin', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => Options::el_margin_description(), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .block-hrc .p-list-inline' => '--bottom-spacing: {{VALUE}}px;' ), ) ); $this->add_responsive_control( 'first_bottom_margin', array( 'label' => esc_html__( 'First Post Bottom Margin', 'foxiz-core' ), 'type' => Controls_Manager::NUMBER, 'description' => esc_html__( 'Input custom bottom margin values (px) for the first post.', 'foxiz-core' ), 'devices' => array( 'desktop', 'tablet', 'mobile' ), 'selectors' => array( '{{WRAPPER}} .block-hrc .p-wrap:first-child' => '--bottom-spacing: {{VALUE}}px;' ), ) ); $this->end_controls_section(); } protected function render() { if ( function_exists( 'foxiz_get_hierarchical_2' ) ) { $settings = $this->get_settings(); $settings['uuid'] = 'uid_' . $this->get_id(); echo \foxiz_get_hierarchical_2( $settings ); } } }
| ver. 1.4 |
Github
|
.
| PHP 8.0.30 | Génération de la page: 0 |
proxy
|
phpinfo
|
Réglages