X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/a8a191541d6f05b08bd8331bdf409af5abfac896..ab53f7a7b9b0e0ca43b6950c3389cd3889e74d82:/cf_dropdown_options.php diff --git a/cf_dropdown_options.php b/cf_dropdown_options.php index 1afce734..3b4663f8 100644 --- a/cf_dropdown_options.php +++ b/cf_dropdown_options.php @@ -39,15 +39,16 @@ if (!$user->isPluginEnabled('cf')) { header('Location: feature_disabled.php'); exit(); } +$field_id = (int)$request->getParameter('field_id'); +$field = CustomFields::getField($field_id); +if (!$field) { + header('Location: access_denied.php'); + exit(); +} +// End of access checks. -$field_id = $request->getParameter('field_id'); $options = CustomFields::getOptions($field_id); -if (false === $options) - $err->add($i18n->get('error.db')); - -$form = new Form('dropdownOptionsForm'); -$smarty->assign('forms', array($form->getName()=>$form->toArray())); $smarty->assign('field_id', $field_id); $smarty->assign('options', $options); $smarty->assign('title', $i18n->get('title.cf_dropdown_options'));