[ SYSTEM ]: Linux wordpress 6.1.0-44-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.164-1 (2026-03-09) x86_64
[ SERVER ]: Apache/2.4.66 (Debian) | PHP: 8.2.30
[ USER ]: www-data | IP: 172.19.30.54
GEFORCE FILE MANAGER
/
var
/
www
/
html
/
wordpress
/
wp-content
/
plugins
/
elementor-pro
/
modules
/
display-conditions
/
conditions
/
base
/
UPLOAD:
NAME
SIZE
QUICK PERMS
ACTIONS
📄 archive-condition-base.php
1,865 B
SET
[ EDIT ]
|
[ DEL ]
📄 condition-base.php
1,053 B
SET
[ EDIT ]
|
[ DEL ]
📄 date-condition-base.php
2,504 B
SET
[ EDIT ]
|
[ DEL ]
📄 title-condition-base.php
1,456 B
SET
[ EDIT ]
|
[ DEL ]
DELETE SELECTED
[ CLOSE ]
EDIT: title-condition-base.php
<?php namespace ElementorPro\Modules\DisplayConditions\Conditions\Base; use Elementor\Controls_Manager; use ElementorPro\Modules\DisplayConditions\Classes\Comparator_Provider; use ElementorPro\Modules\DisplayConditions\Classes\Comparators_Checker; use ElementorPro\Modules\QueryControl\Module as QueryControlModule; abstract class Title_Condition_Base extends Condition_Base { abstract protected function get_query(); public function check( $args ) : bool { $comparator = $args['comparator']; $title = get_the_title(); $titles = array_map( function ( $id ) { return get_the_title( $id ); }, array_column( $args['titles'], 'id' ) ); return Comparators_Checker::check_array_contains( $comparator, [ $title ], $titles ); } public function get_options() { $comparators = Comparator_Provider::get_comparators( [ Comparator_Provider::COMPARATOR_IS, Comparator_Provider::COMPARATOR_IS_NOT, ] ); $this->add_control( 'comparator', [ 'type' => Controls_Manager::SELECT, 'options' => $comparators, 'default' => Comparator_Provider::COMPARATOR_IS, ] ); $this->add_control( 'titles', [ 'type' => QueryControlModule::QUERY_CONTROL_ID, 'autocomplete' => [ 'object' => QueryControlModule::QUERY_OBJECT_POST, 'query' => $this->get_query(), ], 'multiple' => true, 'placeholder' => esc_html__( 'Type to search', 'elementor-pro' ), 'required' => true, ] ); } }