Campaign.php
3 years ago
Current_Traffic.php
3 years ago
Device.php
2 years ago
Geo.php
2 years ago
Page.php
2 years ago
Page_Author_Archive.php
3 years ago
Page_Date_Archive.php
3 years ago
Page_Home.php
3 years ago
Page_Not_Found.php
3 years ago
Page_Post_Type_Archive.php
2 years ago
Page_Search.php
3 years ago
Page_Singular.php
2 years ago
Page_Term_Archive.php
3 years ago
Referrer.php
2 years ago
View_Stats.php
2 years ago
Visitor.php
2 years ago
WooCommerce_Stats.php
3 years ago
Page_Search.php
66 lines
| 1 | <?php |
| 2 | |
| 3 | namespace IAWP_SCOPED\IAWP\Models; |
| 4 | |
| 5 | class Page_Search extends Page |
| 6 | { |
| 7 | private $search_query; |
| 8 | public function __construct($row) |
| 9 | { |
| 10 | $this->search_query = $row->search_query; |
| 11 | parent::__construct($row); |
| 12 | } |
| 13 | public function calculate_url() |
| 14 | { |
| 15 | return \get_search_link($this->search_query); |
| 16 | } |
| 17 | protected function resource_key() : string |
| 18 | { |
| 19 | return 'search_query'; |
| 20 | } |
| 21 | protected function resource_value() : string |
| 22 | { |
| 23 | return $this->search_query; |
| 24 | } |
| 25 | protected function calculate_is_deleted() : bool |
| 26 | { |
| 27 | return \false; |
| 28 | } |
| 29 | protected function calculate_title() |
| 30 | { |
| 31 | return \esc_html__('Search:', 'independent-analytics') . ' "' . $this->search_query . '"'; |
| 32 | } |
| 33 | protected function calculate_type() |
| 34 | { |
| 35 | return 'search-archive'; |
| 36 | } |
| 37 | protected function calculate_type_label() |
| 38 | { |
| 39 | return \esc_html__('Search', 'independent-analytics'); |
| 40 | } |
| 41 | protected function calculate_icon() |
| 42 | { |
| 43 | return '<span class="dashicons dashicons-search"></span>'; |
| 44 | } |
| 45 | protected function calculate_author_id() |
| 46 | { |
| 47 | return null; |
| 48 | } |
| 49 | protected function calculate_author() |
| 50 | { |
| 51 | return null; |
| 52 | } |
| 53 | protected function calculate_avatar() |
| 54 | { |
| 55 | return null; |
| 56 | } |
| 57 | protected function calculate_date() |
| 58 | { |
| 59 | return null; |
| 60 | } |
| 61 | protected function calculate_category() |
| 62 | { |
| 63 | return []; |
| 64 | } |
| 65 | } |
| 66 |