1 file_module_test.module file_module_test_form_submit($form, &$form_state)

Form submission handler for file_module_test_form().

File

core/modules/file/tests/file_module_test/file_module_test.module, line 62
Provides File module pages for testing purposes.

Code

function file_module_test_form_submit($form, &$form_state) {
  if ($form['#tree']) {
    $fid = $form['nested']['file']['#extended'] ? $form_state['values']['nested']['file']['fid'] : $form_state['values']['nested']['file'];
  }
  else {
    $fid = $form['nested']['file']['#extended'] ? $form_state['values']['file']['fid'] : $form_state['values']['file'];
  }
  backdrop_set_message(t('The file id is %fid.', array('%fid' => $fid)));
}