diff --git a/inc/api/v1/property.php b/inc/api/v1/property.php index 3fdc07f9..c16a42d9 100644 --- a/inc/api/v1/property.php +++ b/inc/api/v1/property.php @@ -263,7 +263,7 @@ class Opalestate_Property_Api extends Opalestate_Base_API { $search_min_area = isset( $request['min_area'] ) ? sanitize_text_field( $request['min_area'] ) : ''; $search_max_area = isset( $request['max_area'] ) ? sanitize_text_field( $request['max_area'] ) : ''; $s = isset( $request['search_text'] ) ? sanitize_text_field( $request['search_text'] ) : null; - $per_page = isset( $request['per_page'] ) && $request['per_page'] ? $request['per_page'] : 5; + $per_page = isset( $request['per_page'] ) && $request['per_page'] ? $request['per_page'] : opalestate_options( 'search_property_per_page', 5 ); $paged = isset( $request['page'] ) && $request['page'] ? $request['page'] : 1; if ( isset( $request['paged'] ) && intval( $request['paged'] ) > 0 ) { diff --git a/inc/mixes-functions.php b/inc/mixes-functions.php index ad937892..a14cd8ce 100755 --- a/inc/mixes-functions.php +++ b/inc/mixes-functions.php @@ -1169,7 +1169,7 @@ function opalestate_get_property_statuses() { * @param $key */ function opalestate_get_property_meta_icon( $key ) { - $classes = ''; + $classes = ''; $classes .= 'icon-property-' . esc_attr( $key ); switch ( $key ) { @@ -1214,3 +1214,21 @@ function opalestate_get_property_meta_icon( $key ) { return $classes; } + +/** + * Is enable price field in the search forms? + * + * @return bool + */ +function opalestate_is_enable_price_field() { + return 'on' == opalestate_get_option( 'opalestate_ppt_price_opt', 'on' ); +} + +/** + * Is enable areasize field in the search forms? + * + * @return bool + */ +function opalestate_is_enable_areasize_field() { + return 'on' == opalestate_get_option( 'opalestate_ppt_areasize_opt', 'on' ); +} diff --git a/templates/search-box/advanced-v2.php b/templates/search-box/advanced-v2.php index 641a776c..32401168 100755 --- a/templates/search-box/advanced-v2.php +++ b/templates/search-box/advanced-v2.php @@ -62,13 +62,17 @@ $form_classes = [ -
- -
+ +
+ +
+ -
- -
+ +
+ +
+ -
- -
+ +
+ +
+ -
- -
+ +
+ +
+
diff --git a/templates/search-box/advanced-v4.php b/templates/search-box/advanced-v4.php index 73ab689b..1e17199b 100755 --- a/templates/search-box/advanced-v4.php +++ b/templates/search-box/advanced-v4.php @@ -61,9 +61,13 @@ $form_classes = [
- + + + - + + +
diff --git a/templates/search-box/collapse-advanced.php b/templates/search-box/collapse-advanced.php index 40faeba9..cd5a1393 100755 --- a/templates/search-box/collapse-advanced.php +++ b/templates/search-box/collapse-advanced.php @@ -51,12 +51,12 @@ $form_classes = [
- +
@@ -71,13 +71,17 @@ $form_classes = [
-
- -
+ +
+ +
+ -
- -
+ +
+ +
+
col-md- col-sm- col-xs-12"> @@ -67,20 +67,24 @@ $form_classes = [ -
- -
+ +
+ +
+ -
- -
+ +
+ +
+ - + diff --git a/templates/search-box/collapse-keyword.php b/templates/search-box/collapse-keyword.php index 5356a774..285dcc67 100755 --- a/templates/search-box/collapse-keyword.php +++ b/templates/search-box/collapse-keyword.php @@ -56,7 +56,7 @@ $form_classes = [
@@ -89,13 +89,17 @@ $form_classes = [ -
- -
+ +
+ +
+ -
- -
+ +
+ +
+ + -
- -
+ +
+ +
+ + + +
+ +
+ -
- -
diff --git a/templates/search-box/search-form-v.php b/templates/search-box/search-form-v.php index e6913ac1..3c510001 100755 --- a/templates/search-box/search-form-v.php +++ b/templates/search-box/search-form-v.php @@ -41,7 +41,9 @@ $form_classes = [ 'input' ] ); ?> - + + + " action="" method="GET">
- +
-
- true ) ); ?> +
+ true ] ); ?>
-
-
- 'input' ) ); ?> +
+
+ 'input' ] ); ?>
-
-
- -
- -
-
- -
- - - - -
- + +
+
+
- + + + +
+
+ +
+ + + + + +
+ +
+
diff --git a/templates/search-box/search-form-v3.php b/templates/search-box/search-form-v3.php index 23e7000f..9ad20d06 100755 --- a/templates/search-box/search-form-v3.php +++ b/templates/search-box/search-form-v3.php @@ -52,21 +52,25 @@ $form_classes = [ 'input' ] ); ?>
-
-
- -
+ +
+
+ +
+ -
-
- -
+ +
+
+ +
+ - +