From ff8f3ac473a0bfb9b30173265226734abbd481be Mon Sep 17 00:00:00 2001 From: Hoang Huu Date: Tue, 9 Jun 2020 13:59:06 +0700 Subject: [PATCH] Fix: form vertical widget --- changelog.txt | 3 ++ inc/widgets/search-properties.php | 67 +++++++++++++++++++++---------- opal-estate-pro.php | 6 +-- readme.txt | 5 ++- 4 files changed, 55 insertions(+), 26 deletions(-) diff --git a/changelog.txt b/changelog.txt index 3855897a..d807d694 100755 --- a/changelog.txt +++ b/changelog.txt @@ -1,3 +1,6 @@ += 1.5.5 - 2020-06-09 = +* Fixes - Search box field for vertical form. + = 1.5.4 - 2020-06-05 = * Fixes - Search box field for vertical form. diff --git a/inc/widgets/search-properties.php b/inc/widgets/search-properties.php index 8c56dd8b..2e58edee 100755 --- a/inc/widgets/search-properties.php +++ b/inc/widgets/search-properties.php @@ -53,15 +53,18 @@ class Opalestate_search_properties_Widget extends WP_Widget { public function form( $instance ) { //Set up some default widget settings. - $defaults = [ - 'title' => esc_html__( 'Search Properties', 'opalestate-pro' ), - 'hidden_labels' => 'true', - 'nobutton' => '', - 'style' => 'search-form-v', - 'display_country' => true, - 'display_state' => '', - 'display_city' => '', - ]; + $defaults = apply_filters( 'opalestate_widget_search_properties_args', [ + 'title' => esc_html__( 'Search Properties', 'opalestate-pro' ), + 'hidden_labels' => 'true', + 'nobutton' => '', + 'style' => 'search-form-v', + 'display_country' => 'true', + 'display_state' => 'true', + 'display_city' => 'true', + 'display_more_options' => 'true', + 'info_number_input' => 'true', + ] ); + $instance = wp_parse_args( (array) $instance, $defaults ); ?>

@@ -74,7 +77,7 @@ class Opalestate_search_properties_Widget extends WP_Widget {

@@ -83,7 +86,7 @@ class Opalestate_search_properties_Widget extends WP_Widget {

@@ -92,7 +95,7 @@ class Opalestate_search_properties_Widget extends WP_Widget {

@@ -101,7 +104,7 @@ class Opalestate_search_properties_Widget extends WP_Widget {

@@ -110,7 +113,7 @@ class Opalestate_search_properties_Widget extends WP_Widget {

@@ -119,7 +122,25 @@ class Opalestate_search_properties_Widget extends WP_Widget { +

+ +

+ + +

+ +

+ +

@@ -131,13 +152,15 @@ class Opalestate_search_properties_Widget extends WP_Widget { public function update( $new_instance, $old_instance ) { $instance = $old_instance; //Strip tags from title and name to remove HTML - $instance['title'] = strip_tags( $new_instance['title'] ); - $instance['hidden_labels'] = strip_tags( $new_instance['hidden_labels'] ); - $instance['nobutton'] = strip_tags( $new_instance['nobutton'] ); - $instance['style'] = strip_tags( $new_instance['style'] ); - $instance['display_country'] = strip_tags( $new_instance['display_country'] ); - $instance['display_state'] = strip_tags( $new_instance['display_state'] ); - $instance['display_city'] = strip_tags( $new_instance['display_city'] ); + $instance['title'] = strip_tags( $new_instance['title'] ); + $instance['hidden_labels'] = strip_tags( $new_instance['hidden_labels'] ); + $instance['nobutton'] = strip_tags( $new_instance['nobutton'] ); + $instance['style'] = strip_tags( $new_instance['style'] ); + $instance['display_country'] = strip_tags( $new_instance['display_country'] ); + $instance['display_state'] = strip_tags( $new_instance['display_state'] ); + $instance['display_city'] = strip_tags( $new_instance['display_city'] ); + $instance['display_more_options'] = strip_tags( $new_instance['display_more_options'] ); + $instance['info_number_input'] = strip_tags( $new_instance['info_number_input'] ); return $instance; } diff --git a/opal-estate-pro.php b/opal-estate-pro.php index 9251cd67..4e07f305 100755 --- a/opal-estate-pro.php +++ b/opal-estate-pro.php @@ -3,7 +3,7 @@ * Plugin Name: Opal Estate Pro * Plugin URI: https://wpdocs.gitbook.io/opal-estate/ * Description: Opal Real Estate Plugin is an ideal solution and brilliant choice for you to set up a professional estate website. - * Version: 1.5.4 + * Version: 1.5.5 * Author: WPOPAL * Author URI: http://www.wpopal.com * Requires at least: 4.9 @@ -154,7 +154,7 @@ if ( ! class_exists( 'OpalEstate' ) ) { */ public function __clone() { // Cloning instances of the class is forbidden - _doing_it_wrong( __FUNCTION__, esc_html__( 'Cheatin’ huh?', 'opalestate-pro' ), '1.5.4' ); + _doing_it_wrong( __FUNCTION__, esc_html__( 'Cheatin’ huh?', 'opalestate-pro' ), '1.5.5' ); } /** @@ -163,7 +163,7 @@ if ( ! class_exists( 'OpalEstate' ) ) { public function setup_constants() { // Plugin version if ( ! defined( 'OPALESTATE_VERSION' ) ) { - define( 'OPALESTATE_VERSION', '1.5.4' ); + define( 'OPALESTATE_VERSION', '1.5.5' ); } // Plugin Folder Path diff --git a/readme.txt b/readme.txt index dd909765..237552f2 100755 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Donate link: https://wpdocs.gitbook.io/opal-estate/ Tags: estate, property, opalestate, house for rent, agency for lease, estate submission, agents estate property, property marketplace Requires at least: 4.9 Tested up to: 5.3.2 -Stable tag: 1.5.4 +Stable tag: 1.5.5 License: GPLv3 License URI: http://www.gnu.org/licenses/gpl-3.0.html @@ -150,6 +150,9 @@ This section describes how to install the plugin and get it working. * System tickets support 24/7 available : [free support](https://themelexus.ticksy.com/ "Visit the Plugin support Page") == Changelog == += 1.5.5 - 2020-06-09 = +* Fixes - Search box field for vertical form. + = 1.5.4 - 2020-06-05 = * Fixes - Search box field for vertical form.