Submit button calling wrong submit handler I have a form with 3 different "Submit" buttons, and I want each of them to map to a particular Submit handler.

I have included these items using the following, generic, pattern:

                    array(
                        '#prefix' =&gt; '&lt;td&gt;',
                        '#suffix' =&gt; '&lt;/td&gt;',
                        '#type' =&gt; 'submit',
                        '#value' =&gt; 'Update',
                        '#submit' =&gt; array('user_profile_details_edit_phone_submit')
                    )


But, every time I click the "Submit" button, the incorrect function is called. The function that IS called is the LAST function I add to a submit handler in this way.

Am I doing something wrong?
Drupal uses the name and value of submit buttons to identify which was pressed, and subsequently which submit handlers to run. If the names and values of all three buttons are the same, the FAPI will only be able to use one of them (in this case the last one).

To fix it you can assign a unique #name property to each of the buttons.