| @@ -9,15 +9,25 @@ | ||
| 9 | 9 | |
| 10 | 10 | if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly |
| 11 | 11 | ?> |
| 12 | 12 | |
| 13 | -<form name="ph_property_search" class="property-search-form property-search-form-<?php echo $id; ?> clear" action="<?php echo get_post_type_archive_link( 'property' ); ?>" method="get" role="form"> | |
| 13 | +<?php do_action( 'propertyhive_before_search_form', $id ); ?> | |
| 14 | 14 | |
| 15 | - <?php foreach ( $form_controls as $key => $field ) : ?> | |
| 15 | +<form name="ph_property_search" class="property-search-form property-search-form-<?php echo esc_attr($id); ?> clear" action="<?php echo esc_url( apply_filters( 'propertyhive_search_form_action', get_post_type_archive_link( 'property' ) ) ); ?>" method="get" role="form"> | |
| 16 | 16 | |
| 17 | - <?php ph_form_field( $key, $field ); ?> | |
| 17 | + <?php do_action( 'propertyhive_before_search_form_controls', $id, $form_controls ); ?> | |
| 18 | 18 | |
| 19 | + <?php foreach ( $form_controls as $propertyhive_key => $propertyhive_field ) : ?> | |
| 20 | + | |
| 21 | + <?php ph_form_field( $propertyhive_key, $propertyhive_field ); ?> | |
| 22 | + | |
| 19 | 23 | <?php endforeach; ?> |
| 20 | 24 | |
| 21 | - <input type="submit" value="<?php _e( 'Search', 'propertyhive' ); ?>"> | |
| 25 | + <?php do_action( 'propertyhive_after_search_form_controls', $id, $form_controls ); ?> | |
| 22 | 26 | |
| 23 | -</form> | |
| 27 | + <input type="submit" value="<?php echo esc_attr__( 'Search', 'propertyhive' ); ?>"> | |
| 28 | + | |
| 29 | + <?php do_action( 'propertyhive_after_search_form_submit', $id, $form_controls ); ?> | |
| 30 | + | |
| 31 | +</form> | |
| 32 | + | |
| 33 | +<?php do_action( 'propertyhive_after_search_form', $id ); ?> | |