foreach ($listQuestion as $question_id => $values) { $question->delete($values); } //suppresion section $section = new PluginFormcreatorSection(); $listSection = $section->find("plugin_formcreator_forms_id = '{$formID}'"); foreach ($listSection as $section_id => $values) { $section->delete($values); } //suppression target $target = new PluginFormcreatorTarget(); $listTarget = $target->find("plugin_formcreator_forms_id = '{$formID}'"); foreach ($listTarget as $target_id => $values) { $target->delete($values); } $form->redirectToList(); } else { if (isset($_POST["restore"])) { $form->check($_POST["id"], 'd'); $form->restore($_POST); $form->redirectToList(); } else { if (isset($_REQUEST["purge"])) { $form->check($_REQUEST["id"], 'd'); $form->delete($_REQUEST, 1); $form->redirectToList(); } else { if (isset($_POST["update"])) { $form->check($_POST["id"], 'w'); $form->update($_POST); Html::back();