Example #1
0
    if (ossim_error()) {
        die(ossim_error());
    }
    if ($directive_editor->clone_directive(POST('clone_directive_id'), POST('file'))) {
        $msg_success = _("The directive was successfully cloned");
    } else {
        $msg_error = _("Unable to clone this directive");
    }
}
if (POST('enable_directive_id') != "") {
    ossim_valid(POST('enable_directive_id'), OSS_DIGIT, 'illegal:' . _("Directive ID"));
    ossim_valid(POST('file'), OSS_ALPHA, OSS_PUNC, 'illegal:' . _("File"));
    if (ossim_error()) {
        die(ossim_error());
    }
    $directive_editor->enable_directive(POST('file'), POST('enable_directive_id'));
    $msg_success = _("The directive was successfully enabled");
    $toggled = POST('file');
}
if (POST('disable_directive_id') != "") {
    ossim_valid(POST('disable_directive_id'), OSS_DIGIT, 'illegal:' . _("Directive ID"));
    ossim_valid(POST('file'), OSS_ALPHA, OSS_PUNC, 'illegal:' . _("File"));
    if (ossim_error()) {
        die(ossim_error());
    }
    $directive_editor->disable_directive(POST('file'), POST('disable_directive_id'));
    $msg_success = _("The directive was successfully disabled");
    $toggled = POST('file');
}
if (POST('touser_directive_id') != "") {
    ossim_valid(POST('touser_directive_id'), OSS_DIGIT, 'illegal:' . _("Directive ID"));