GravityView  2.17
The best, easiest way to display Gravity Forms entries on your website.
Variables
field-select-html.php File Reference

Go to the source code of this file.

Variables

 $display_value = $gravityview->display_value
 
 $entry = $gravityview->entry->as_entry()
 
if(! isset( $gravityview)||empty( $gravityview->template)) $field = $gravityview->field->field
 The default select field output template. More...
 
 $field_settings = $gravityview->field->as_configuration()
 
 $show_label = apply_filters( 'gravityview/fields/select/output_label', ( 'label' === \GV\Utils::get( $field_settings, 'choice_display' ) ), $entry, $field, $gravityview )
 
if( $show_label &&! empty( $field->choices) &&is_array( $field->choices) &&'' !==$display_value) else
 

Variable Documentation

◆ $display_value

$display_value = $gravityview->display_value

Definition at line 15 of file field-select-html.php.

◆ $entry

$entry = $gravityview->entry->as_entry()

Definition at line 16 of file field-select-html.php.

◆ $field

if (! isset($gravityview)||empty($gravityview->template)) $field = $gravityview->field->field

The default select field output template.

$gravityview

Since
2.0

Definition at line 14 of file field-select-html.php.

◆ $field_settings

$field_settings = $gravityview->field->as_configuration()

Definition at line 17 of file field-select-html.php.

◆ $show_label

$show_label = apply_filters( 'gravityview/fields/select/output_label', ( 'label' === \GV\Utils::get( $field_settings, 'choice_display' ) ), $entry, $field, $gravityview )
Runs Filter:
gravityview/fields/select/output_label Override whether to show the value or the label of a Select field
Since
1.5.2
Parameters
bool$show_labelTrue: Show the label of the Choice; False: show the value of the Choice. Default: false
array$entryGF Entry
GF_Field_Select$fieldGravity Forms Select field
Since
2.0
Parameters
\GV\Template_Context$gravityviewThe context

Definition at line 28 of file field-select-html.php.

◆ else

if ($show_label &&! empty($field->choices) &&is_array($field->choices) &&'' !==$display_value) else
Initial value:

Definition at line 32 of file field-select-html.php.