# templately/3.3.0/includes/Builder/Conditions/ProductSearch.php

Templately – Elementor &amp; Gutenberg Template Library: 6500+ Free &amp; Pro Ready Templates And Cloud!, version 3.3.0. 21 lines.

- Page: https://pluginprobe.com/plugins/templately/3.3.0/code/includes/Builder/Conditions/ProductSearch.php
- Raw: https://pluginprobe.com/plugins/templately/3.3.0/raw/includes/Builder/Conditions/ProductSearch.php
- Modified: 2024-01-24T10:10:10+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/templately/3.3.0/code/includes/Builder/Conditions/ProductSearch.php#L10-L20`.

```php
<?php

namespace Templately\Builder\Conditions;

class ProductSearch extends Search {
	public function get_priority(): int {
		return 40;
	}

	public function get_label(): string {
		return __( 'Product Search', 'templately' );
	}

	public function get_name(): string {
		return 'product_search';
	}

	public function check( $args = [] ): bool {
		return is_search() && 'product' === get_query_var( 'post_type' );
	}
}
```
