# sellkit/1.7.9/includes/contact-segmentation/operators/ends-with.php

SellKit – Funnel builder and checkout optimizer for WooCommerce to sell more, faster, version 1.7.9. 71 lines.

- Page: https://pluginprobe.com/plugins/sellkit/1.7.9/code/includes/contact-segmentation/operators/ends-with.php
- Raw: https://pluginprobe.com/plugins/sellkit/1.7.9/raw/includes/contact-segmentation/operators/ends-with.php
- Modified: 2023-12-04T06:56:30+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/sellkit/1.7.9/code/includes/contact-segmentation/operators/ends-with.php#L10-L20`.

```php
<?php

namespace Sellkit\Contact_Segmentation\Operators;

use Sellkit\Contact_Segmentation\Operator_Base;

defined( 'ABSPATH' ) || die();

/**
 * Class Ends_With
 *
 * @package Sellkit\Contact_Segmentation\Conditions
 * @since 1.1.0
 */
class Ends_With extends Operator_Base {

	/**
	 * Condition name.
	 *
	 * @since 1.1.0
	 */
	public function get_name() {
		return 'end-with';
	}

	/**
	 * Condition title.
	 *
	 * @since 1.1.0
	 */
	public function get_title() {
		return __( 'end with', 'sellkit' );
	}

	/**
	 * Conditions.
	 *
	 * @since 1.1.0
	 */
	public function get_conditions() {
		return [
			'utm-source',
			'utm-medium',
			'utm-campaign',
			'utm-content',
			'utm-term',
			'referral-source-url',
			'billing-city',
			'billing-city-checkout',
			'shipping-city',
			'visitor-city',
			'url-query-string',
		];
	}

	/**
	 * Condition title.
	 *
	 * @since 1.1.0
	 * @param mixed $value            mixed The value of current value.
	 * @param mixed $condition_value  The value of condition input.
	 */
	public function is_valid( $value, $condition_value ) {
		if ( str_ends_with( $value, $condition_value ) ) {
			return true;
		}

		return false;
	}
}

```
