フォームの状態に関する情報を保存するようにフォームを変更します。次に、すべてのファイルのアップロードが完了していない場合にすぐに戻る送信関数の先頭に新しいケースを追加すると、フォームが再描画されます。
function modulename_uploader_form(&$form_stuff=null) {
//the function that sets your form array
$stuff = (isset($form_stuff['values'])) ?
$form_stuff['storage']['done_uploading'] :
false; //if values isnt set, this is the first visit.
$form_stuff['storage']['done_uploading'] = done_uploading();
.... the rest of your form creation function.
function modulename_uploader_submit($form, &$form_stuff) {
if($form_stuff['storage']['done_uploading']) {
return;
}
... rest of the function
フォームの処理が完了したら、必ずストレージ変数を設定解除してください。drupal で複数ページのフォームをググることもできます。