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.
Hello
I am using module Select (or other) and I want to know if there is possible to chnage position of button other. I want this button always on top (i.e. always first in a list).
Thank you for answers.
Comments
Comment #1
kejmil CreditAttribution: kejmil commentedComment #2
VM CreditAttribution: VM commentedNote: The assigned* status of an issue is only to be used if you are providing a patch or otherwise fixing an issue. for more information on how to set the status fields in issues see: https://www.drupal.org/node/156119
Comment #3
legolasboNew features are developed against 7.x-3.x.
Comment #4
legolasboI think adding this option would add complexity to an already complex settings form. It is also very easy to implement this by implementing hook_preprocess_HOOK as demonstrated below.
Comment #5
markusd1984 CreditAttribution: markusd1984 commentedI understand it may be complex to add but given that the main purposes of the module is to provide an "other" option and the whole thing being a list i'd say it's likely many people will also use the
Add 'Other' value to the list of choices for this field.
which likely results a long list growing quickly and this the "other" options disappearing in the noise.Therefore I think having a setting to keep it easily reachable and visually noticeable is really important, in fact perhaps one needs to use some css to visually highlight and differentiate it. Perhaps a another way would be to provide "other" or "Create new values" via a button next to the list could be more obvious but also even more complex of course. :)
Therefore one can only make the label very long and descriptive in efforts to try differentiate it visually from all the existing values in the list.
Thanks for the hook, that worked a treat, just applies it to all Other lists of course, an individual setting would allow to choose when or when not to use it, e.g. in small list or where it's not likely i would keep it disabled but on long list especially where usually new titles are being created than enabled.