24 var
$icon =
'dashicons-admin-links';
27 $this->label = esc_html__(
'Website',
'gk-gravityview' );
28 parent::__construct();
34 unset( $field_options[
'show_as_link'] );
36 if(
'edit' === $context ) {
37 return $field_options;
43 $field_options[
'anchor_text'] = array(
45 'label' => __(
'Link Text:',
'gk-gravityview' ),
46 'desc' => __(
'Define custom link text. Leave blank to display the URL',
'gk-gravityview' ),
48 'merge_tags' =>
'force',
52 $field_options[
'truncatelink'] = array(
55 'label' => __(
'Shorten Link Display',
'gk-gravityview' ),
56 'tooltip' => __(
'Only show the domain for a URL instead of the whole link.',
'gk-gravityview' ),
57 'desc' => __(
'Don’t show the full URL, only show the domain.',
'gk-gravityview' ),
67 $field_options[
'new_window'][
'value'] =
true;
68 $field_options[
'new_window'][
'priority'] = 2000;
70 return $field_options;
Modify field settings by extending this class.
field_options( $field_options, $template_id, $field_id, $context, $input_type, $form_id)
add_field_support( $key, &$field_options)
new GravityView_Field_Website
Add custom options for date fields.
if(empty( $created_by)) $form_id
if(false !==strpos( $value, '00:00')) $field_id
string $field_id ID of the field being displayed