@@ -7,26 +7,26 @@ |
||
7 | 7 | |
8 | 8 | var $name = 'post_content'; |
9 | 9 | |
10 | - var $search_operators = array( 'is', 'isnot', 'contains', 'starts_with', 'ends_with' ); |
|
10 | + var $search_operators = array('is', 'isnot', 'contains', 'starts_with', 'ends_with'); |
|
11 | 11 | |
12 | 12 | var $_gf_field_class_name = 'GF_Field_Post_Content'; |
13 | 13 | |
14 | 14 | var $label = 'Body'; |
15 | 15 | |
16 | 16 | public function __construct() { |
17 | - $this->label = esc_attr__( 'Body', 'gravityview' ); |
|
17 | + $this->label = esc_attr__('Body', 'gravityview'); |
|
18 | 18 | parent::__construct(); |
19 | 19 | } |
20 | 20 | |
21 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
21 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
22 | 22 | |
23 | - unset( $field_options['show_as_link'] ); |
|
23 | + unset($field_options['show_as_link']); |
|
24 | 24 | |
25 | - if( 'edit' === $context ) { |
|
25 | + if ('edit' === $context) { |
|
26 | 26 | return $field_options; |
27 | 27 | } |
28 | 28 | |
29 | - $this->add_field_support('dynamic_data', $field_options ); |
|
29 | + $this->add_field_support('dynamic_data', $field_options); |
|
30 | 30 | |
31 | 31 | return $field_options; |
32 | 32 | } |
@@ -11,7 +11,7 @@ |
||
11 | 11 | var $label = 'Custom Field'; |
12 | 12 | |
13 | 13 | public function __construct() { |
14 | - $this->label = esc_attr__( 'Custom Field', 'gravityview' ); |
|
14 | + $this->label = esc_attr__('Custom Field', 'gravityview'); |
|
15 | 15 | parent::__construct(); |
16 | 16 | } |
17 | 17 | } |
@@ -11,7 +11,7 @@ |
||
11 | 11 | var $label = 'Excerpt'; |
12 | 12 | |
13 | 13 | public function __construct() { |
14 | - $this->label = esc_attr__( 'Excerpt', 'gravityview' ); |
|
14 | + $this->label = esc_attr__('Excerpt', 'gravityview'); |
|
15 | 15 | parent::__construct(); |
16 | 16 | } |
17 | 17 | } |
@@ -11,19 +11,19 @@ |
||
11 | 11 | |
12 | 12 | var $label = 'Post ID'; |
13 | 13 | |
14 | - var $search_operators = array( 'is', 'isnot', 'greater_than', 'less_than' ); |
|
14 | + var $search_operators = array('is', 'isnot', 'greater_than', 'less_than'); |
|
15 | 15 | |
16 | 16 | /** |
17 | 17 | * GravityView_Field_Post_ID constructor. |
18 | 18 | */ |
19 | 19 | public function __construct() { |
20 | - $this->label = __( 'Post ID', 'gravityview' ); |
|
20 | + $this->label = __('Post ID', 'gravityview'); |
|
21 | 21 | parent::__construct(); |
22 | 22 | } |
23 | 23 | |
24 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
24 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
25 | 25 | |
26 | - $this->add_field_support('link_to_post', $field_options ); |
|
26 | + $this->add_field_support('link_to_post', $field_options); |
|
27 | 27 | |
28 | 28 | return $field_options; |
29 | 29 | } |
@@ -12,22 +12,22 @@ |
||
12 | 12 | var $label = 'Post Image'; |
13 | 13 | |
14 | 14 | public function __construct() { |
15 | - $this->label = __( 'Post Image', 'gravityview' ); |
|
15 | + $this->label = __('Post Image', 'gravityview'); |
|
16 | 16 | parent::__construct(); |
17 | 17 | } |
18 | 18 | |
19 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
19 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
20 | 20 | |
21 | - unset ( $field_options['search_filter'] ); |
|
21 | + unset ($field_options['search_filter']); |
|
22 | 22 | |
23 | - if( 'edit' === $context ) { |
|
23 | + if ('edit' === $context) { |
|
24 | 24 | return $field_options; |
25 | 25 | } |
26 | 26 | |
27 | - $this->add_field_support('link_to_post', $field_options ); |
|
27 | + $this->add_field_support('link_to_post', $field_options); |
|
28 | 28 | |
29 | 29 | // @since 1.5.4 |
30 | - $this->add_field_support('dynamic_data', $field_options ); |
|
30 | + $this->add_field_support('dynamic_data', $field_options); |
|
31 | 31 | |
32 | 32 | return $field_options; |
33 | 33 | } |
@@ -7,25 +7,25 @@ |
||
7 | 7 | |
8 | 8 | var $name = 'post_tags'; |
9 | 9 | |
10 | - var $search_operators = array( 'is', 'in', 'not in', 'isnot', 'contains'); |
|
10 | + var $search_operators = array('is', 'in', 'not in', 'isnot', 'contains'); |
|
11 | 11 | |
12 | 12 | var $_gf_field_class_name = 'GF_Field_Post_Tags'; |
13 | 13 | |
14 | 14 | var $label = 'Tags'; |
15 | 15 | |
16 | 16 | public function __construct() { |
17 | - $this->label = __( 'Tags', 'gravityview' ); |
|
17 | + $this->label = __('Tags', 'gravityview'); |
|
18 | 18 | parent::__construct(); |
19 | 19 | } |
20 | 20 | |
21 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
21 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
22 | 22 | |
23 | - if( 'edit' === $context ) { |
|
23 | + if ('edit' === $context) { |
|
24 | 24 | return $field_options; |
25 | 25 | } |
26 | 26 | |
27 | - $this->add_field_support('dynamic_data', $field_options ); |
|
28 | - $this->add_field_support('link_to_term', $field_options ); |
|
27 | + $this->add_field_support('dynamic_data', $field_options); |
|
28 | + $this->add_field_support('link_to_term', $field_options); |
|
29 | 29 | |
30 | 30 | return $field_options; |
31 | 31 | } |
@@ -7,26 +7,26 @@ |
||
7 | 7 | |
8 | 8 | var $name = 'post_title'; |
9 | 9 | |
10 | - var $search_operators = array( 'is', 'isnot', 'contains', 'starts_with', 'ends_with' ); |
|
10 | + var $search_operators = array('is', 'isnot', 'contains', 'starts_with', 'ends_with'); |
|
11 | 11 | |
12 | 12 | var $_gf_field_class_name = 'GF_Field_Post_Title'; |
13 | 13 | |
14 | 14 | var $label = 'Title'; |
15 | 15 | |
16 | 16 | public function __construct() { |
17 | - $this->label = esc_attr__( 'Title', 'gravityview' ); |
|
17 | + $this->label = esc_attr__('Title', 'gravityview'); |
|
18 | 18 | parent::__construct(); |
19 | 19 | } |
20 | 20 | |
21 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
21 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
22 | 22 | |
23 | - if( 'edit' === $context ) { |
|
23 | + if ('edit' === $context) { |
|
24 | 24 | return $field_options; |
25 | 25 | } |
26 | 26 | |
27 | - $this->add_field_support('link_to_post', $field_options ); |
|
27 | + $this->add_field_support('link_to_post', $field_options); |
|
28 | 28 | |
29 | - $this->add_field_support('dynamic_data', $field_options ); |
|
29 | + $this->add_field_support('dynamic_data', $field_options); |
|
30 | 30 | |
31 | 31 | return $field_options; |
32 | 32 | } |
@@ -4,14 +4,14 @@ |
||
4 | 4 | |
5 | 5 | var $name = 'radio'; |
6 | 6 | |
7 | - var $search_operators = array( 'is', 'in', 'not in', 'isnot', 'contains'); |
|
7 | + var $search_operators = array('is', 'in', 'not in', 'isnot', 'contains'); |
|
8 | 8 | |
9 | 9 | var $_gf_field_class_name = 'GF_Field_Radio'; |
10 | 10 | |
11 | 11 | var $label = 'Radio Buttons'; |
12 | 12 | |
13 | 13 | public function __construct() { |
14 | - $this->label = esc_attr__( 'Radio Buttons', 'gravityview' ); |
|
14 | + $this->label = esc_attr__('Radio Buttons', 'gravityview'); |
|
15 | 15 | parent::__construct(); |
16 | 16 | } |
17 | 17 |
@@ -15,11 +15,11 @@ discard block |
||
15 | 15 | |
16 | 16 | function __construct() { |
17 | 17 | |
18 | - $this->label = esc_attr__( 'Radio Buttons', 'gravityview' ); |
|
18 | + $this->label = esc_attr__('Radio Buttons', 'gravityview'); |
|
19 | 19 | |
20 | 20 | parent::__construct(); |
21 | 21 | |
22 | - add_filter( 'gravityview_field_entry_value_section', array( $this, 'prevent_empty_field' ) ); |
|
22 | + add_filter('gravityview_field_entry_value_section', array($this, 'prevent_empty_field')); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | /** |
@@ -31,13 +31,13 @@ discard block |
||
31 | 31 | * |
32 | 32 | * @return string If output was empty, return an empty HTML comment tag. Otherwise, return output. |
33 | 33 | */ |
34 | - function prevent_empty_field( $output = '' ) { |
|
35 | - return empty( $output ) ? '<!-- -->' : $output; |
|
34 | + function prevent_empty_field($output = '') { |
|
35 | + return empty($output) ? '<!-- -->' : $output; |
|
36 | 36 | } |
37 | 37 | |
38 | - function field_options( $field_options, $template_id, $field_id, $context, $input_type ) { |
|
38 | + function field_options($field_options, $template_id, $field_id, $context, $input_type) { |
|
39 | 39 | |
40 | - unset ( $field_options['search_filter'], $field_options['show_as_link'] ); |
|
40 | + unset ($field_options['search_filter'], $field_options['show_as_link']); |
|
41 | 41 | |
42 | 42 | // Set the default CSS class to gv-section, which applies a border and top/bottom margin |
43 | 43 | $field_options['custom_class']['value'] = 'gv-section'; |