コード例 #1
0
    } else {
        if (is_array($validation_errors) && !empty($validation_errors)) {
            $data['status'] = 'error';
        }
    }
    if ($data['status'] == 'error') {
        $txt_error = '<div>' . _('We Found the following errors') . ":</div>\n\t\t\t\t\t  <div style='padding:2px 10px 5px 10px;'>" . implode('<br/>', $validation_errors) . '</div>';
        $config_nt = array('content' => $txt_error, 'options' => array('type' => 'nf_error', 'cancel_button' => FALSE), 'style' => 'width: 80%; margin: 20px auto; text-align: left;');
        $nt = new Notification('nt_1', $config_nt);
        $nt->show();
        Util::make_form('POST', 'pluginref.php');
        exit;
    } else {
        $db = new ossim_db();
        $conn = $db->connect();
        Compliance::update($conn, $data);
        $db->close();
        ?>
		<script type='text/javascript'>
    		var params          = new Array();
        		params['dir_info']  = "1";
        	    params['directive'] = "<?php 
        echo $sid;
        ?>
";
        	    params['reload']    = true;
        		parent.GB_hide(params);
		</script>
		<?php 
        exit;
    }
コード例 #2
0
ファイル: modifygeneral.php プロジェクト: jhbsz/ossimTest
ossim_valid($imp_image, OSS_DIGIT, 'illegal:' . _("imp_image"));
ossim_valid($imp_financial, OSS_DIGIT, 'illegal:' . _("imp_financial"));
ossim_valid($D, OSS_DIGIT, 'illegal:' . _("D"));
ossim_valid($I, OSS_DIGIT, 'illegal:' . _("I"));
ossim_valid($C, OSS_DIGIT, 'illegal:' . _("C"));
ossim_valid($net_anomaly, OSS_DIGIT, 'illegal:' . _("net_anomaly"));
if (ossim_error()) {
    die(ossim_error());
}
if (!empty($insert)) {
    require_once 'ossim_db.inc';
    require_once 'classes/Compliance.inc';
    $db = new ossim_db();
    $conn = $db->connect();
    $descr = "";
    Compliance::update($conn, $descr, $sid, $targeted, $untargeted, $approach, $exploration, $penetration, $generalmalware, $imp_qos, $imp_infleak, $imp_lawful, $imp_image, $imp_financial, $D, $I, $C, $net_anomaly);
    $db->close($conn);
}
?>
    <p><?php 
echo _("Category succesfully updated");
?>
</p>
    <script>document.location.href="general.php"</script>
<?php 
// update indicators on top frame
$OssimWebIndicator->update_display();
?>

</body>
</html>