It always bugged me and made it unclear that the form not found error would come before all the reasons why the form wasn't found. As logically all those reasons were found first in order to conclude that the form wasn't found.
The other problem this creates is that the error messages about what actually went wrong get mixed up with all the subsequent errors related to the form not submitting properly.
This patch changes the order so that all reasons why form wasn't found are output before the form was not found message.
This patch also clarifies on the drupalPost documentation how to submit values for multiple selects, something which I have had a number of people ask me.
The way to submit muti-steps forms is also not clear, so I have documented that as well in response to recent issue. #292375: Multistep forms drupalPost doesn't work
Comment | File | Size | Author |
---|---|---|---|
#7 | simpletest_form_handling.patch | 2.21 KB | boombatower |
#6 | simpletest_form_handling.patch | 2.21 KB | boombatower |
#2 | simpletest_form_handling_test.patch | 847 bytes | boombatower |
#1 | simpletest_form_handling.patch | 2.22 KB | boombatower |
Comments
Comment #1
boombatower CreditAttribution: boombatower commentedComment #2
boombatower CreditAttribution: boombatower commentedYou can test this with the following patch.
Comment #3
dmitrig01 CreditAttribution: dmitrig01 commentedComment #4
dmitrig01 CreditAttribution: dmitrig01 commentedThat's wrong - name[] is going to be value2. Youd have to do:
which I don't think is supported
Comment #5
boombatower CreditAttribution: boombatower commentedhmm not sure how I managed that.
Comment #6
boombatower CreditAttribution: boombatower commentedFrom looking at the code this would appear to be correct, but I will test shortly. This is the main reason I want these areas documented, as they are not clear and the code is rather hard to decipher.
Comment #7
boombatower CreditAttribution: boombatower commentedMerged with #296547: Change message when attempting to find fields.
Comment #8
Dries CreditAttribution: Dries commentedCommitted to CVS HEAD. Thanks.
Comment #9
Anonymous (not verified) CreditAttribution: Anonymous commentedAutomatically closed -- issue fixed for two weeks with no activity.