Whenever we use system_settings_form and something alters that form, any alterations by default get put below the 'Save configuration' button because it has no weight at all. Why can't we just add a default weight of 100 to $form['buttons'] so we save a step for most of our module developers? For 99% of cases we want these buttons on the bottom and not in the middle of a form.

Comments

dave reid’s picture

Status: Active » Needs review
StatusFileSize
new966 bytes
dave reid’s picture

dave reid’s picture

Re-rolled for latest $form['actions'] array.

jide’s picture

Status: Needs review » Reviewed & tested by the community

Seems pretty straightforward :) Had this issue numerous times too.

dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to CVS HEAD.

jide’s picture

Status: Fixed » Needs work

Should not we do the same for other forms ?

dave reid’s picture

Status: Needs work » Fixed

@jide: Yes and file issues for their respective modules.

jide’s picture

@Dave Reid: That would overcomplicate things don't you think ? There are plenty of them, and since #482816: Make a consistent wrapper around submit buttons addressed all submit buttons in one issue, I thought we could do the same for the weight issue.

Status: Fixed » Closed (fixed)
Issue tags: -DX (Developer Experience), -system_settings_form

Automatically closed -- issue fixed for 2 weeks with no activity.