We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Add-Ons
default app icon

GB Default Value

By Gilbert Lin
Publishing Utilities

Description

Dynamically specify default values for text fields or file names for files.

Dynamically specify default values for text fields or file names for files. You can use the field values, categories, and/or author member fields from the entry to generate the default values.

Screenshot of GB Default Value settings page

Screenshot of GB Default Value on field settings

Usage

There are 2 places where you can specify the default value: - The GB Default Value settings page - Field settings page

Channel

Set the channel for this default value rule to be applied to for the specified field.

Field

Set the field to have the default value rule.

Title and URL Title

You can use other fields to dynamically generate the values Title and URL Title field. I’m using jQuery to remove the validation process on those 2 fields so if the validation is still happening, it might be because there is something wrong with the extension script.

Value

This is like a template. You can use {exp:channel:entries} loops or {embed="templates"} to set the values. To access the field values, categories and author member fields from the entry, you can prefix your tag with this like {this:title}, {this:custom_field}, {this:categories backspace="1"}{category_id},{/this:categories}, {author:member_id}, {author:member_field_short_name}.

{this:categories}

  • {active}
  • {category_count}
  • {category_description}
  • {category_group}
  • {category_id}
  • {category_image}
  • {category_name}
  • {category_url_title}
  • {parent_id}

Author information

  • {author:member_id}
  • {author:email}
  • {author:username}
  • {author:screen_name}
  • {author:member_custom_field}

Force?

Do you want the default value rule to kick in even if the field is not empty? For file fields, you must toggle this on for the file names to be changed.

Run on updating entry?

A lot of people has asked for this so I’m enabling this. If you want the default value to kick in even when an entry is being udpated, toggle this on. You may need to turn Force? on to overwrite the existing values. Title and URL Title excluded. For files, the file name will be updated.

Supported fields

  • Text fields
  • File (only the file name)
  • Checkboxes
  • Multi Select
  • Radio
  • Select
  • Selectable Buttons

Note

  • gbdefaultvalueplacehoder is a reserved value for Title and URL Title fields
Information
Version 1.2.1
Last Update 6 months ago
Compatibility EE 7, 6, 5
License Commercial
Links
  • Documentation
  • Support
ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.