Origin commit
This commit is contained in:
89
templates/search-box/advanced-v2.php
Executable file
89
templates/search-box/advanced-v2.php
Executable file
@@ -0,0 +1,89 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v2 search
|
||||
* // https://wpresidence.net/advanced-search-type-1/
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 4;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 12,
|
||||
1 => 0,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 10,
|
||||
1 => 2,
|
||||
];
|
||||
}
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : false;
|
||||
$display_city = isset( $display_city ) ? $display_city : false;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-2',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[0] ); ?> col-md-<?php echo esc_attr( $grid[0] ); ?> col-sm-<?php echo esc_attr( $grid[0] ); ?>">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( $display_country ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/country-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_state ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/state-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_city ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/city-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[1] ); ?> col-md-<?php echo esc_attr( $grid[1] ); ?> col-sm-<?php echo esc_attr( $grid[1] ); ?>">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
73
templates/search-box/advanced-v3.php
Executable file
73
templates/search-box/advanced-v3.php
Executable file
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v3 search
|
||||
* // https://wpresidence.net/advanced-search-type-4/
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 4;
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : false;
|
||||
$display_city = isset( $display_city ) ? $display_city : false;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-3',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( $display_country ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/country-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_state ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/state-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_city ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/city-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
83
templates/search-box/advanced-v4.php
Executable file
83
templates/search-box/advanced-v4.php
Executable file
@@ -0,0 +1,83 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v4 search
|
||||
* // https://wpresidence.net/advanced-search-type-4/
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 4;
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : false;
|
||||
$display_city = isset( $display_city ) ? $display_city : false;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-4',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/location' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/radius' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( $display_country ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/country-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_state ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/state-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_city ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/city-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-6">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
70
templates/search-box/advanced-v5.php
Executable file
70
templates/search-box/advanced-v5.php
Executable file
@@ -0,0 +1,70 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v5 search
|
||||
* // http://homevillas.chimpgroup.com/home-v5/
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 3,
|
||||
1 => 3,
|
||||
2 => 3,
|
||||
3 => 3,
|
||||
4 => 0,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 3,
|
||||
1 => 3,
|
||||
2 => 3,
|
||||
3 => 2,
|
||||
4 => 1,
|
||||
];
|
||||
}
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : false;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-5',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[0] ); ?> col-md-<?php echo esc_attr( $grid[0] ); ?> col-sm-<?php echo esc_attr( $grid[0] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[1] ); ?> col-md-<?php echo esc_attr( $grid[1] ); ?> col-sm-<?php echo esc_attr( $grid[1] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/location' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[2] ); ?> col-md-<?php echo esc_attr( $grid[2] ); ?> col-sm-<?php echo esc_attr( $grid[2] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status-bar', [ 'hide_default_status' => 1 ] ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[3] ); ?> col-md-<?php echo esc_attr( $grid[3] ); ?> col-sm-<?php echo esc_attr( $grid[3] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-1 col-md-1 col-sm-1 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_more_options ) : ?>
|
||||
<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/more-options' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
42
templates/search-box/advanced-v6.php
Executable file
42
templates/search-box/advanced-v6.php
Executable file
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v6 search
|
||||
* // http://homevillas.chimpgroup.com/demo-v7/
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : false;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-6',
|
||||
isset( $nobutton ) && $nobutton ? 'no-submit-btn' : 'has-submit-btn',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opalestate-search-form__item">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="opalestate-search-form__item">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-text' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
87
templates/search-box/collapse-city.php
Executable file
87
templates/search-box/collapse-city.php
Executable file
@@ -0,0 +1,87 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for collapse city search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$unique_id = esc_attr( wp_unique_id() );
|
||||
$GLOBALS['group-info-column'] = 4;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 7,
|
||||
1 => 4,
|
||||
2 => 1,
|
||||
3 => 0,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 6,
|
||||
1 => 3,
|
||||
2 => 1,
|
||||
3 => 2,
|
||||
];
|
||||
}
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--collapse-city',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[0] ) ?> col-md-<?php echo esc_attr( $grid[0] ); ?> col-sm-<?php echo esc_attr( $grid[0] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-city-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[1] ); ?> col-md-<?php echo esc_attr( $grid[1] ); ?> col-sm-<?php echo esc_attr( $grid[1] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[2] ); ?> col-md-<?php echo esc_attr( $grid[2] ); ?> col-sm-<?php echo esc_attr( $grid[2] ); ?> col-xs-12">
|
||||
<button type="button" class="opal-collapse-button opalestate-collapse-btn btn btn-primary" data-collapse="#collapse-city-<?php echo esc_attr( $unique_id ); ?>">
|
||||
<i class="fa fa-caret-down" aria-hidden="true"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[3] ); ?> col-md-<?php echo esc_attr( $grid[3] ); ?> col-sm-<?php echo esc_attr( $grid[3] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<div id="collapse-city-<?php echo esc_attr( $unique_id ); ?>" class="opal-collapse-container collapse-city-inputs">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-3 col-md-3 col-sm-3 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
109
templates/search-box/collapse-keyword.php
Executable file
109
templates/search-box/collapse-keyword.php
Executable file
@@ -0,0 +1,109 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for collapse keyword search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 4;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 5,
|
||||
1 => 3,
|
||||
2 => 3,
|
||||
3 => 1,
|
||||
4 => 0,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 5,
|
||||
1 => 2,
|
||||
2 => 2,
|
||||
3 => 1,
|
||||
4 => 2,
|
||||
];
|
||||
}
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : false;
|
||||
$display_city = isset( $display_city ) ? $display_city : false;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--collapse-keyword',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo absint( $grid[0] ); ?> col-md-<?php echo absint( $grid[0] ); ?> col-sm-<?php echo absint( $grid[0] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo absint( $grid[1] ); ?> col-md-<?php echo absint( $grid[1] ); ?> col-sm-<?php echo absint( $grid[1] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo absint( $grid[2] ); ?> col-md-<?php echo absint( $grid[2] ); ?> col-sm-<?php echo absint( $grid[2] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo absint( $grid[3] ); ?> col-md-<?php echo absint( $grid[3] ); ?> col-sm-<?php echo absint( $grid[3] ); ?> col-xs-12">
|
||||
<button type="button" class="opal-collapse-button opalestate-collapse-btn btn btn-primary" data-collapse="#collapse-keyword-<?php echo esc_attr( $unique_id ); ?>">
|
||||
<i class="fa fa-caret-down" aria-hidden="true"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-<?php echo absint( $grid[4] ); ?> col-md-<?php echo absint( $grid[4] ); ?> col-sm-<?php echo absint( $grid[4] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<div id="collapse-keyword-<?php echo esc_attr( $unique_id ); ?>" class="opal-collapse-container collapse-keyword-inputs">
|
||||
<div class="opal-row">
|
||||
<?php if ( $display_country ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/country-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_state ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/state-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_city ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-3 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/city-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-6 col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
1
templates/search-box/fields/areasize.php
Executable file
1
templates/search-box/fields/areasize.php
Executable file
@@ -0,0 +1 @@
|
||||
<?php opalestate_property_areasize_field_template(); ?>
|
||||
3
templates/search-box/fields/city-select.php
Executable file
3
templates/search-box/fields/city-select.php
Executable file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
$scity = isset( $_GET['city'] ) ? sanitize_text_field( $_GET['city'] ) : '';
|
||||
Opalestate_Taxonomy_City::dropdown_list( $scity );
|
||||
3
templates/search-box/fields/country-select.php
Executable file
3
templates/search-box/fields/country-select.php
Executable file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
$slocation = isset( $_GET['location'] ) ? sanitize_text_field( $_GET['location'] ): opalestate_get_session_location_val();
|
||||
Opalestate_Taxonomy_Location::dropdown_list( $slocation );
|
||||
21
templates/search-box/fields/group-info.php
Executable file
21
templates/search-box/fields/group-info.php
Executable file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
$fields = OpalEstate_Search::get_setting_search_fields();
|
||||
if ( ! $fields ) {
|
||||
return;
|
||||
}
|
||||
|
||||
$type = isset( $type ) ? $type : '';
|
||||
$column = isset( $GLOBALS['group-info-column'] ) ? $GLOBALS['group-info-column'] : 3;
|
||||
if( $type != 'input' ) {
|
||||
$col_class = 'col-lg-' . ( 12 / absint( $column ) ) . ' col-md-' . ( 12 / absint( $column ) ) . ' col-sm-' . ( 12 / absint( $column ) );
|
||||
} else {
|
||||
$col_class = 'column-item';
|
||||
}
|
||||
|
||||
foreach ( $fields as $key => $label ): ?>
|
||||
<?php if ( 'areasize' == $key ) : continue; endif; ?>
|
||||
<div class="<?php echo esc_attr( $col_class ); ?>">
|
||||
<?php opalestate_property_render_field_template( $key, $label, $type ); ?>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
|
||||
2
templates/search-box/fields/location.php
Executable file
2
templates/search-box/fields/location.php
Executable file
@@ -0,0 +1,2 @@
|
||||
<label class="opalestate-label opalestate-label--location-text"><?php esc_html_e( 'Location', 'opalestate-pro' ) ?></label>
|
||||
<input class="form-control" name="location_text" placeholder="<?php esc_attr_e( 'Location', 'opalestate-pro' ); ?>">
|
||||
33
templates/search-box/fields/more-options.php
Executable file
33
templates/search-box/fields/more-options.php
Executable file
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for more options search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$unique_id = esc_attr( wp_unique_id() );
|
||||
$amenities = Opalestate_Taxonomy_Amenities::get_list();
|
||||
|
||||
if ( ! $amenities ) {
|
||||
return;
|
||||
}
|
||||
|
||||
?>
|
||||
<div class="search-more-options">
|
||||
<a href="#" class="opal-collapse-button" data-collapse="#more-options-<?php echo esc_attr( $unique_id ); ?>"><?php esc_html_e( 'More Search Options', 'opalestate-pro' ); ?></a>
|
||||
|
||||
<div id="more-options-<?php echo esc_attr( $unique_id ); ?>" class="opal-collapse-container more-options-container">
|
||||
<div class="more-options-items">
|
||||
<?php foreach ( $amenities as $amenity ) : ?>
|
||||
<div class="more-options-item">
|
||||
<label class="more-options-label">
|
||||
<input type="checkbox" name="amenities[]" value="<?php echo esc_attr( $amenity->slug ); ?>">
|
||||
<?php echo esc_html( $amenity->name ); ?>
|
||||
</label>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
20
templates/search-box/fields/price.php
Executable file
20
templates/search-box/fields/price.php
Executable file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
$search_min_price = isset( $_GET['min_price'] ) ? sanitize_text_field( $_GET['min_price'] ): opalestate_options( 'search_min_price', 0 );
|
||||
$search_max_price = isset( $_GET['max_price'] ) ? sanitize_text_field( $_GET['max_price'] ): opalestate_options( 'search_max_price', 10000000 );
|
||||
|
||||
$data = [
|
||||
'id' => 'price',
|
||||
'decimals' => opalestate_get_price_decimals(),
|
||||
'unit' => opalestate_currency_symbol() . ' ',
|
||||
'ranger_min' => opalestate_options( 'search_min_price', 0 ),
|
||||
'ranger_max' => opalestate_options( 'search_max_price', 10000000 ),
|
||||
'input_min' => $search_min_price,
|
||||
'input_max' => $search_max_price,
|
||||
];
|
||||
|
||||
if ( opalestate_options( 'currency_position', 'before' ) == 'before' ) {
|
||||
$data['unit_position'] = 'prefix';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php opalesate_property_slide_ranger_template( esc_html__( 'Price', 'opalestate-pro' ), $data ); ?>
|
||||
15
templates/search-box/fields/radius.php
Executable file
15
templates/search-box/fields/radius.php
Executable file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
$search_min_radius = isset( $_GET['min_radius'] ) ? sanitize_text_field( $_GET['min_radius'] ) : opalestate_options( 'search_min_radius', 0 );
|
||||
$search_max_radius = isset( $_GET['max_radius'] ) ? sanitize_text_field( $_GET['max_radius'] ): opalestate_options( 'search_max_radius', 10000000 );
|
||||
|
||||
$data = [
|
||||
'id' => 'radius',
|
||||
'unit' => 'miles',
|
||||
'ranger_min' => opalestate_options( 'search_min_radius', 0 ),
|
||||
'ranger_max' => opalestate_options( 'search_max_radius', 10000000 ),
|
||||
'input_min' => $search_min_radius,
|
||||
'input_max' => $search_max_radius,
|
||||
];
|
||||
|
||||
opalesate_property_slide_ranger_template( esc_html__( 'Radius:', 'opalestate-pro' ), $data );
|
||||
?>
|
||||
44
templates/search-box/fields/search-city-text.php
Executable file
44
templates/search-box/fields/search-city-text.php
Executable file
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
$max_price = 10;
|
||||
$start = 1;
|
||||
$unit = 'KM';
|
||||
$location_text = isset( $_GET['location_text'] ) ? sanitize_text_field( $_GET['location_text'] ): "";
|
||||
$geo_lat = isset( $_GET['geo_lat'] ) ? sanitize_text_field( $_GET['geo_lat'] ): "";
|
||||
$geo_long = isset( $_GET['geo_long'] ) ? sanitize_text_field( $_GET['geo_long'] ): "";
|
||||
$max_geo_radius = isset( $_GET['geo_radius'] ) ? sanitize_text_field( $_GET['geo_radius'] ): $start;
|
||||
$data_deposit = [
|
||||
'id' => 'geo_radius',
|
||||
'decimals' => 0,
|
||||
'unit' => $unit,
|
||||
'ranger_min' => 0,
|
||||
'ranger_max' => $max_price,
|
||||
'input_min' => 0,
|
||||
'input_max' => $max_price,
|
||||
'mode' => 1,
|
||||
'start' => $max_geo_radius,
|
||||
];
|
||||
|
||||
?>
|
||||
<div class="input-search-city opalestate-search-opal-map">
|
||||
<label class="opalestate-label opalestate-label--geo-location"><?php esc_html_e( 'Location', 'opalestate-pro' ); ?></label>
|
||||
<input class="form-control opal-map-search" name="location_text" value="<?php echo esc_attr( $location_text ); ?>" placeholder="<?php esc_attr_e( 'Type City or Area', 'opalestate-pro' ); ?>">
|
||||
<input class="form-control opal-map-latitude" name="geo_lat" value="<?php echo esc_attr( $geo_lat ); ?>" type="hidden">
|
||||
<input class="form-control opal-map-longitude" name="geo_long" type="hidden" value="<?php echo esc_attr( $geo_long ); ?>">
|
||||
<div class="map-remove"><i class="fa fa-close"></i></div>
|
||||
<div class="opalestate-popup">
|
||||
<div class="popup-head">
|
||||
<span><i class="fa fa-location-arrow"></i></span>
|
||||
</div>
|
||||
<div class="popup-body">
|
||||
<div class="popup-close"><i class="fa fa-times" aria-hidden="true"></i></div>
|
||||
<div class="contact-share-form-container">
|
||||
<h6><?php echo esc_html__( 'Show with in.', 'opalestate-pro' ); ?></h6>
|
||||
<div class="box-content ">
|
||||
<?php opalesate_property_slide_ranger_template( esc_html__( 'Radius', 'opalestate-pro' ), $data_deposit ); ?>
|
||||
<p><a href="#"><?php echo esc_html__( 'Of My Location', 'opalestate-pro' ); ?></a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
2
templates/search-box/fields/search-text.php
Executable file
2
templates/search-box/fields/search-text.php
Executable file
@@ -0,0 +1,2 @@
|
||||
<label class="opalestate-label opalestate-label--keyword"><?php esc_html_e( 'Keyword', 'opalestate-pro' ); ?></label>
|
||||
<input class="form-control" name="search_text" placeholder="<?php esc_attr_e( 'Type keyword', 'opalestate-pro' ); ?>">
|
||||
3
templates/search-box/fields/state-select.php
Executable file
3
templates/search-box/fields/state-select.php
Executable file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
$sstate = isset( $_GET['state'] ) ? $_GET['state'] : '';
|
||||
Opalestate_Taxonomy_State::dropdown_list( $sstate );
|
||||
28
templates/search-box/fields/status-bar.php
Executable file
28
templates/search-box/fields/status-bar.php
Executable file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
$statuses = Opalestate_Taxonomy_Status::get_list();
|
||||
|
||||
if ( ! $statuses ) {
|
||||
return;
|
||||
}
|
||||
|
||||
$sstatus = isset( $_GET['status'] ) ? sanitize_text_field( $_GET['status'] ): -1;
|
||||
$label = isset( $label ) ? esc_html( $label ) : esc_html__( 'All', 'opalestate-pro' );
|
||||
$style = isset( $style ) && $style ? $style : '';
|
||||
?>
|
||||
|
||||
<div class="search-status-bar <?php echo esc_attr( $style ) ? 'search-status-bar--' . $style : ''; ?>">
|
||||
<ul class="list-inline clearfix list-property-status">
|
||||
<?php if ( ! isset( $hide_default_status ) ) : ?>
|
||||
<li class="status-item <?php if ( $sstatus == -1 ): ?> active<?php endif; ?>" data-id="-1">
|
||||
<span><?php echo esc_html( $label ); ?></span>
|
||||
</li>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php foreach ( $statuses as $status ): ?>
|
||||
<li class="status-item <?php if ( $sstatus == $status->slug ) : ?> active<?php endif; ?>" data-id="<?php echo esc_attr( $status->slug ); ?>">
|
||||
<span><?php echo esc_html( $status->name ); ?> </span>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<input type="hidden" value="<?php echo esc_attr( $sstatus ); ?>" name="status"/>
|
||||
</div>
|
||||
4
templates/search-box/fields/status.php
Executable file
4
templates/search-box/fields/status.php
Executable file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
$status = isset( $_GET['status'] ) ? sanitize_text_field( $_GET['status'] ): -1;
|
||||
Opalestate_Taxonomy_Status::dropdown_list( $status );
|
||||
?>
|
||||
3
templates/search-box/fields/submit-button.php
Executable file
3
templates/search-box/fields/submit-button.php
Executable file
@@ -0,0 +1,3 @@
|
||||
<button type="submit" class="<?php echo apply_filters( 'opalestate_search_form_submit_classes', 'btn btn-secondary btn-search' ); ?>">
|
||||
<?php esc_html_e('Search', 'opalestate-pro'); ?>
|
||||
</button>
|
||||
9
templates/search-box/fields/types.php
Executable file
9
templates/search-box/fields/types.php
Executable file
@@ -0,0 +1,9 @@
|
||||
<?php
|
||||
$stypes = isset( $_GET['types'] ) ? $_GET['types'] : -1;
|
||||
|
||||
if( isset($ismultiple) ) {
|
||||
Opalestate_Taxonomy_Type::get_multi_check_list( $stypes );
|
||||
} else {
|
||||
Opalestate_Taxonomy_Type::dropdown_list();
|
||||
}
|
||||
?>
|
||||
77
templates/search-box/search-form-h.php
Executable file
77
templates/search-box/search-form-h.php
Executable file
@@ -0,0 +1,77 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for advanced v1 search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : false;
|
||||
$display_city = isset( $display_city ) ? $display_city : false;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--advanced-1',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="searchbox-top">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status-bar', [ 'style' => 2 ] ); ?>
|
||||
</div>
|
||||
|
||||
<div class="opal-row">
|
||||
<?php if ( $display_country ) : ?>
|
||||
<div class="col-lg-4 col-md-4 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/country-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_state ) : ?>
|
||||
<div class="col-lg-4 col-md-4 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/state-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $display_city ) : ?>
|
||||
<div class="col-lg-4 col-md-4 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/city-select' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="col-lg-8 col-md-8 col-sm-12">
|
||||
<div class="opal-row">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info' ); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-3 col-md-3 col-sm-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
58
templates/search-box/search-form-v.php
Executable file
58
templates/search-box/search-form-v.php
Executable file
@@ -0,0 +1,58 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for vertival search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 1;
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : true;
|
||||
$display_city = isset( $display_city ) ? $display_city : true;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--vertical',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<?php
|
||||
if ( $display_country ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/country-select' );
|
||||
}
|
||||
|
||||
if ( $display_state ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/state-select' );
|
||||
}
|
||||
|
||||
if ( $display_city ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/city-select' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info', [ 'type' => 'input' ] ); ?>
|
||||
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
|
||||
63
templates/search-box/search-form-v2.php
Executable file
63
templates/search-box/search-form-v2.php
Executable file
@@ -0,0 +1,63 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for vertival search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 1;
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--vertical-2',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-form-content">
|
||||
<div class="form-item form-item--location-text">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-city-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--types">
|
||||
<h6> <?php esc_html_e( 'Types', 'opalestate-pro' );?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' , array( 'ismultiple' => true ) ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--information">
|
||||
<h6> <?php esc_html_e( 'Information', 'opalestate-pro' );?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info', array( 'type' => 'input' ) ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--price">
|
||||
<h6> <?php esc_html_e( 'Price', 'opalestate-pro' );?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--area">
|
||||
<h6> <?php esc_html_e( 'Area', 'opalestate-pro' );?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="form-item form-item--submit">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
|
||||
80
templates/search-box/search-form-v3.php
Executable file
80
templates/search-box/search-form-v3.php
Executable file
@@ -0,0 +1,80 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for vertival search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
$GLOBALS['group-info-column'] = 1;
|
||||
|
||||
$display_country = isset( $display_country ) ? $display_country : true;
|
||||
$display_state = isset( $display_state ) ? $display_state : true;
|
||||
$display_city = isset( $display_city ) ? $display_city : true;
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : true;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--vertical-3',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-form-content">
|
||||
<?php if ( $display_country || $display_state || $display_city ) : ?>
|
||||
<div class="form-item form-item--location">
|
||||
<h6> <?php esc_html_e( 'Location', 'opalestate-pro' ); ?></h6>
|
||||
<?php
|
||||
if ( $display_country ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/country-select' );
|
||||
}
|
||||
|
||||
if ( $display_state ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/state-select' );
|
||||
}
|
||||
|
||||
if ( $display_city ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/city-select' );
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="form-item form-item--types">
|
||||
<h6> <?php esc_html_e( 'Types', 'opalestate-pro' ); ?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types', [ 'ismultiple' => true ] ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--information">
|
||||
<h6> <?php esc_html_e( 'Information', 'opalestate-pro' ); ?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/group-info', [ 'type' => 'input' ] ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--price">
|
||||
<h6> <?php esc_html_e( 'Price', 'opalestate-pro' ); ?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/price' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="form-item form-item--area">
|
||||
<h6> <?php esc_html_e( 'Area', 'opalestate-pro' ); ?></h6>
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/areasize' ); ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="form-item form-item--submit">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
|
||||
64
templates/search-box/simple-city.php
Executable file
64
templates/search-box/simple-city.php
Executable file
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for simple city search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 6,
|
||||
1 => 3,
|
||||
2 => 3,
|
||||
3 => 3,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 6,
|
||||
1 => 2,
|
||||
2 => 2,
|
||||
3 => 2,
|
||||
];
|
||||
}
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : false;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--simple-city',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo absint( $grid[0] ); ?> col-md-<?php echo absint( $grid[0] ); ?> col-sm-<?php echo absint( $grid[0] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-city-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo absint( $grid[1] ); ?> col-md-<?php echo absint( $grid[1] ); ?> col-sm-<?php echo absint( $grid[1] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo absint( $grid[2] ) ?> col-md-<?php echo absint( $grid[2] ); ?> col-sm-<?php echo absint( $grid[2] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-<?php echo absint( $grid[3] ); ?> col-md-<?php echo absint( $grid[3] ); ?> col-sm-<?php echo absint( $grid[3] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
64
templates/search-box/simple-keyword.php
Executable file
64
templates/search-box/simple-keyword.php
Executable file
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
/**
|
||||
* The template for simple keyword search
|
||||
*
|
||||
* @version 1.0.0
|
||||
*/
|
||||
|
||||
defined( 'ABSPATH' ) || exit;
|
||||
|
||||
if ( isset( $nobutton ) && $nobutton ) {
|
||||
$grid = [
|
||||
0 => 6,
|
||||
1 => 3,
|
||||
2 => 3,
|
||||
3 => 3,
|
||||
];
|
||||
} else {
|
||||
$grid = [
|
||||
0 => 6,
|
||||
1 => 2,
|
||||
2 => 2,
|
||||
3 => 2,
|
||||
];
|
||||
}
|
||||
|
||||
$display_more_options = isset( $display_more_options ) ? $display_more_options : false;
|
||||
|
||||
$form_classes = [
|
||||
'opalestate-search-form',
|
||||
'opalestate-search-form--simple-keyword',
|
||||
isset( $hidden_labels ) && $hidden_labels ? 'hidden-labels' : '',
|
||||
];
|
||||
|
||||
?>
|
||||
|
||||
<form class="<?php echo esc_attr( implode( ' ', array_map( 'sanitize_html_class', $form_classes ) ) ); ?>" action="<?php echo esc_url( opalestate_get_search_link() ); ?>" method="GET">
|
||||
<div class="opal-row">
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[0] ); ?> col-md-<?php echo esc_attr( $grid[0] ); ?> col-sm-<?php echo esc_attr( $grid[0] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/search-text' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[1] ); ?> col-md-<?php echo esc_attr( $grid[1] ); ?> col-sm-<?php echo esc_attr( $grid[1] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/types' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[2] ); ?> col-md-<?php echo esc_attr( $grid[2] ); ?> col-sm-<?php echo esc_attr( $grid[2] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/status' ); ?>
|
||||
</div>
|
||||
|
||||
<?php if ( ! isset( $nobutton ) || ! $nobutton ) : ?>
|
||||
<div class="col-lg-<?php echo esc_attr( $grid[3] ); ?> col-md-<?php echo esc_attr( $grid[3] ); ?> col-sm-<?php echo esc_attr( $grid[3] ); ?> col-xs-12">
|
||||
<?php echo opalestate_load_template_path( 'search-box/fields/submit-button' ); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
if ( $display_more_options ) {
|
||||
echo opalestate_load_template_path( 'search-box/fields/more-options' );
|
||||
}
|
||||
?>
|
||||
|
||||
<?php do_action( 'opalestate_after_search_properties_form' ); ?>
|
||||
</form>
|
||||
Reference in New Issue
Block a user