PluginProbe
WP Directory Kit / 1.3.1
WP Directory Kit v1.3.1
1.5.6 1.5.5 1.5.4 1.5.3 trunk 1.1.0 1.1.6 1.1.8 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.8 1.4.0 1.4.1 All 35 releases
wpdirectorykit / application / views / search_fields / TEXTAREA.php

TEXTAREA.php in WP Directory Kit 1.3.1, at application/views/search_fields/TEXTAREA.php

42 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * The template for Search field TEXTAREA.
4 *
5 * This is the template that field layout for search form
6 *
7 */
8
9 if ( ! defined( 'ABSPATH' ) ) {
10 exit; // Exit if accessed directly.
11 }
12 ?>
13 <?php
14 $field_key = 'field_'.wmvc_show_data('idfield',$field_data);
15 $field_attr_id = 'wdk_field_'.wmvc_show_data('idfield', $field_data);
16 $placeholder = wmvc_show_data('placeholder', $field_data, wmvc_show_data('field_label', $field_data));
17 $field_value = '';
18 $placeholder = esc_html__($placeholder,'wpdirectorykit');
19
20 $query_type = wmvc_show_data('query_type', $field_data, '');
21
22 if(!empty($query_type) && $query_type !='min_max')
23 $field_key .='_'.$query_type;
24
25 if(isset($_GET[$field_key])) {
26 $field_value = sanitize_text_field($_GET[$field_key]);
27 }
28
29 if($query_type =='min')
30 $placeholder = esc_html__('Min','wpdirectorykit').' '.$placeholder;
31
32 if($query_type =='max')
33 $placeholder = esc_html__('Max','wpdirectorykit').' '.$placeholder;
34 wdk_search_fields_toggle();
35 ?>
36
37 <div class="wdk-field wdk-col wdk_search_<?php echo esc_attr($field_key);?> <?php echo esc_attr(wmvc_show_data('field_type', $field_data)); ?> <?php echo esc_attr(wmvc_show_data('class', $field_data)); ?> wdk_field_id_<?php echo wmvc_show_data('idfield',$field_data);?>">
38 <label class="wdk-field-label"><?php echo esc_html(wmvc_show_data('field_label', $field_data)); ?></label>
39 <div class="wdk-field-group">
40 <input class="wdk-control" name="<?php echo esc_attr($field_key); ?>" type="text" id="<?php echo esc_attr($field_attr_id); ?>" value="<?php echo esc_attr($field_value); ?>" placeholder="<?php echo esc_attr(trim($placeholder));?>">
41 </div>
42 </div>