GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — projectsend/groups-add.php at develop · sitecode/projectsend Expand file tree/ Copy pathgroups-add.phpMore file actions 62 lines (52 loc) · 1.68 KB / Copy pathgroups-add.phpFile metadata and controls62 lines (52 loc) · 1.68 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 <?php /** * Show the form to add a new group. */ require_once 'bootstrap.php'; check_access_enhanced(['create_groups']); $active_nav = 'groups'; $page_title = __('Add clients group', 'cftp_admin'); $page_id = 'group_form'; include_once ADMIN_VIEWS_DIR . DS . 'header.php'; $group = new \ProjectSend\Classes\Groups(); if ($_POST) { /** * Clean the posted form values to be used on the groups actions, * and again on the form if validation failed. */ $group_arguments = [ 'name' => $_POST['name'], 'description' => $_POST['description'], 'members' => (!empty($_POST['members'])) ? $_POST['members'] : null, 'public' => (isset($_POST["public"])) ? 1 : 0, ]; /** Validate the information from the posted form. */ $group->set($group_arguments); $create = $group->create(); if ($create['status'] === 'success') { $flash->success($create['message']); $redirect_to = BASE_URI . 'groups-edit.php?id=' . $create['id']; } else { $flash->error($create['message']); $redirect_to = BASE_URI . 'groups-add.php'; } ps_redirect($redirect_to); } ?> <div class="row"> <div class="col-12 col-sm-12 col-lg-6"> <div class="white-box"> <div class="white-box-interior"> <?php // If the form was submitted with errors, show them here. echo $group->getValidationErrors(); // Include the form. $groups_form_type = 'new_group'; include_once FORMS_DIR . DS . 'groups.php'; ?> </div> </div> </div> </div> <?php include_once ADMIN_VIEWS_DIR . DS . 'footer.php'; |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |