2

私は多くのフォームに共通のモジュールに取り組んでいます。$form_id をパラメーターとして送信ハンドラーに渡し、送信関数でそれに応じてフォーム値を設定する必要があります。

function ppi_form_alter(&$form, &$form_state, $form_id){

  $form['#submit'][]="action_form_submit";

}

function action_form_submit($form, &$form_state) {
  //here I need to get the form_id of the form and form_set_value accordingly ... How can I know the form value?
}

form_submit の form_id を知る方法はありますか?

ありがとう!

4

1 に答える 1