Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: Views Bulk Operations (VBO) 4.4.8 Minor update available for module views_bulk_operations (4.4.8). Release: Commerce Authorize.Net 2.0.0 Major update available for module commerce_authnet (2.0.0). Usage Milestone: Easy Breadcrumb Module easy_breadcrumb crossed 100,000 active installs. Release: SDC Components 2.0.3 Minor update available for module sdc_components (2.0.3). Release: Commerce ML Starter 8.x-1.94 Minor update available for module cmlstarter (8.x-1.94). Release: Field Label Visibility (an intuitive approach to editing node forms) 1.0.3 Minor update available for module field_label_visibility (1.0.3). Release: DruxtJS 1.3.1 Minor update available for module druxt (1.3.1). Release: Monobank payment API 1.0.4 Minor update available for module monobank (1.0.4). Release: Personified 1.0.4 Minor update available for module personified (1.0.4). Module Revived: Fleetview client 1.1.2 Module fleetview_client updated after 16 months of inactivity (1.1.2).

Safeword

250 sites Security covered Drupal 11 · not 10
View on drupal.org

Safeword provides a field type that stores a human-readable name and a machine-readable name. This is useful for generating URL aliases, views arguments, and more, allowing users to edit only a portion of a path while keeping other parts safe.

It's often useful to provide two versions of user input - one that's intended for human viewing and another that's for use in database queries, URLs, and so on. In Drupal, this is generally known as a 'Name' and 'Machine name' pair. Drupal even provides a FormAPI element to simplify the process of entering these matched pairs.

Safeword provides a custom field type that stores two strings using the name/machine name approach. It can be useful when generating PathAuto aliases, exposing Views arguments, and so on.

One common use is to not give users permission to 'Create and edit URL aliases' and instead give them access to a Safeword field which uses the node title as it's source. So that users can only edit a limited part of the path, keeping safe the other parts that your site features may rely on.

Features

Can use the node Title or taxonomy term name field as the source of the machine name.

Can provide it's own text field as the source of the machine name.

Machine name field is shown next to the source field, clicking 'Edit' makes the machine name editable in it's own field.

Option to show a live preview of the full path to the node or term while the machine name part of it is being edited.

Option to require machine names to be unique per content type or vocabulary.

Option to convert accented characters like øéåî to Roman letter equivalents, uses integration with the Transliteration module.

Can remove HTML intelligently without leaving 'p', 'div', etc. in the machine name.

Similar Modules

Machine Name

Machine Name module adds a field type into which the user enters a machine name, it's main function is to validate that the input conforms to the machine name format.

Safeword module is different to Machine Name module as it provides a standard text field and when text is input displays a matching machine name field which automatically converts the text into a machine name formatted version, which can also be hand edited.

Depends on

Dependencies of the latest stable release

  • field Drupal core
  • text Drupal core

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
2
Tracked since
Jul 2026
Latest release
1 month ago
Releases (12 mo)
2 ▲ from 0
Maintenance
Active

Releases

Version Type Core Release date
2.0.1 Stable 11 Jul 25, 2026
2.0.x-dev Dev 11 Jul 25, 2026