Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Machine name element was added to core, which has basically same functionality as custom js + textfield element that currently use. It's should be less code/maintenance to use machine_name and likely best practices.
Comment | File | Size | Author |
---|---|---|---|
#6 | features.machine-name-core-element-1259362-6.patch | 5.02 KB | undertext |
Comments
Comment #1
joachim CreditAttribution: joachim commentedUpping this to a bug, as the implementation in Features is broken:
1. Start typing a module name
2. Click to edit the machine name yourself
3. Enter your own machine name
4. Go back and change the module name
5. The JS clobbers what you typed in the machine name with the updated human name text.
This is not the same behaviour as core's element.
Comment #2
joachim CreditAttribution: joachim commentedHere's a patch.
(This also takes care of #1331886: don't disable machine name in rebuild form -- it prevents renaming of features BTW.)
Comment #3
mpotter CreditAttribution: mpotter commentedLet's see if we can get this re-rolled and tested for the 2.x branch.
Comment #4
mpotter CreditAttribution: mpotter commentedComment #6
undertext CreditAttribution: undertext commentedReroll
Comment #7
joachim CreditAttribution: joachim commentedLooks good to me, though as it was originally my patch I don't think I can RTBC...
Comment #8
torotil CreditAttribution: torotil commentedPatch looks good and it works fine for me. Used this to fix a weird bug with the machine-name field always being submitted empty (although it had a valid value).
Comment #10
hefox CreditAttribution: hefox commentedThanks