fapi

Multiple Forms on One Page

I noticed a bug on my page where one form in a block was being submitted to another form that was in the body of the page.

By default, when a form has no "#action" defined in the $form array, it will post to itself--on whichever page it is displayed--and magically work :)

But when you have more than one form on one page, make sure each form has an #action property set to a valid menu callback that routes back to drupal_get_form for each form.

:)

Syndicate content