Default Link Text Widget
This module provides a new field widget for Link fields that allows site administrators to define a default value for the link text (title) at the field widget level.
Features
- Define a global default text for links (e.g., "Read more" or "Click here") that automatically populates the link text field when editors create content.
- Extends the core Drupal Link widget, maintaining all standard functionality while adding the default value option.
- Reduces repetitive data entry for editors by pre-filling common link labels.
When to use this module?
Use this module when you have a content type with a link field where the link text is often the same across most entries. For example, a "Related Resource" link that usually says "View Document".
Why not to use just core Link features?
Because core fails to allow to set a default link text value for links without setting a default URL value. There is a validation constraint forcing it. This is an old known core issue: Default value for link text is not saved.
Post-Installation
- Install the "Default Link Text Widget" module as you would any other Drupal module.
- Configure a Link field:
- Go to Structure > Content types (or your preferred entity type).
- Click Manage form display for the content type you want to modify.
- Find your Link field and change the widget to Default Link.
- Set the default value:
- Click the gear icon (Settings) next to the Default Link widget.
- Enter your desired text in the Default value for link text field.
- Click Update and then Save at the bottom of the page.
- Create a new piece of content. You will see that the link text field is now pre-populated with your chosen default value!
Depends on
Dependencies of the latest stable release
- link Drupal core
Required by
Tracked projects that depend on this one
No tracked projects depend on this one yet.
Activity
Releases
| Version | Type | Core | Notes | Release date | |
|---|---|---|---|---|---|
| 1.0.0 | Stable | 10–11 | Sep 7, 2026 |