PluginProbe ʕ •ᴥ•ʔ
Pods – Custom Content Types and Fields / 2.7.31.4
Pods – Custom Content Types and Fields v2.7.31.4
2.7.31.4 2.8.23.5 2.9.19.5 3.0.10.5 3.1.4.3 3.2.8.4 3.3.9.2 2.8.23.4 2.9.19.4 3.0.10.4 3.1.4.2 3.2.8.3 3.3.9.1 trunk 1.14.8 2.7.31.3 2.8.23.3 2.9.19.3 3.0.10.3 3.1.4.1 3.2.0 3.2.1 3.2.1.1 3.2.2 3.2.4 3.2.5 3.2.6 3.2.7 3.2.7.1 3.2.8 3.2.8.1 3.2.8.2 3.3.0 3.3.1 3.3.2 3.3.3 3.3.4 3.3.5 3.3.6 3.3.7 3.3.8 3.3.9
pods / ui / front / filters.php
pods / ui / front Last commit date
pagination 5 days ago filters.php 5 days ago form.php 5 days ago view.php 5 days ago widgets.php 5 days ago
filters.php
31 lines
1 <?php
2 // Don't load directly.
3 if ( ! defined( 'ABSPATH' ) ) {
4 die( '-1' );
5 }
6 ?>
7 <form method="get" class="pods-form-filters pods-form-filters-<?php echo esc_attr( $pod->pod ); ?>" action="<?php echo esc_attr( $action ); ?>">
8 <input type="hidden" name="type" value="<?php echo esc_attr( $pod->pod ); ?>" />
9
10 <?php
11 foreach ( $fields as $name => $field ) {
12 if ( in_array( $field['type'], array( 'pick', 'taxonomy' ), true ) && 'pick-custom' !== $field['pick_object'] && ! empty( $field['pick_object'] ) ) {
13 $field['options']['pick_format_type'] = 'single';
14 $field['options']['pick_format_single'] = 'dropdown';
15 $field['options']['pick_select_text'] = '-- ' . $field['label'] . ' --';
16
17 $filter = pods_var_raw( 'filter_' . $name, 'get', '' );
18
19 // @todo Support other field types.
20 $field['type'] = 'pick';
21
22 echo PodsForm::field( 'filter_' . $name, $filter, $field['type'], $field, $pod->pod, $pod->id() );
23 }
24 }
25 ?>
26
27 <input type="text" class="pods-form-filters-search" name="<?php echo esc_attr( $pod->search_var ); ?>" value="<?php echo esc_attr( $search ); ?>" />
28
29 <input type="submit" class="pods-form-filters-submit" value="<?php echo esc_attr( $label ); ?>" />
30 </form>
31