20 $this->label = esc_html__(
'Password',
'gk-gravityview' );
24 parent::__construct();
26 add_filter(
'gravityview/field/password/value', array( $this,
'get_value' ), 10, 6 );
57 add_filter(
'gravityview/common/get_form_fields', array( $this,
'add_form_fields' ), 10, 3 );
59 add_filter(
'gravityview/template/field_label', array( $this,
'field_label' ), 10, 4 );
77 if( ! is_numeric(
$field[
'id'] ) || ! empty(
$field[
'custom_label'] ) ) {
81 $field_object = GFFormsModel::get_field(
$form,
$field[
'id'] );
83 if( $field_object &&
'password' === $field_object->type ) {
103 foreach ( $fields as $key =>
$field ) {
104 if(
'password' ===
$field[
'type'] ) {
107 if( floor( $key ) === floatval( $key ) ) {
109 if( ! empty(
$field[
'parent'] ) ) {
114 unset(
$field[
'parent'] );
120 unset( $fields[ $key ] );
Modify field settings by extending this class.
field_label( $label='', $field=array(), $form=array(), $entry=array())
Use the GV Admin Field label for the Password field instead of the per-input setting.
add_hooks()
Add filters to modify the front-end label and the Add Field label.
if(gravityview() ->plugin->is_GF_25()) $form
add_form_fields( $fields=array(), $form=array(), $include_parent_field=true)
If a form has list fields, add the columns to the field picker.
new GravityView_Field_Password
get_value( $value, $field, $view, $source, $entry, $request)
Filter the value of the field, future.