Exemplo n.º 1
0
require_once 'ossim_db.inc';
require_once 'ossim_conf.inc';
// Database Object
$db = new ossim_db();
$conn = $db->connect();
$type = GET('type') != "" ? GET('type') : POST('type');
$subtype = GET('subtype') != "" ? GET('subtype') : POST('subtype');
$new = $type == "" && $subtype == "" ? 1 : 0;
if (POST('save') == "1") {
    $match = POST('match');
    $list = POST('prelist');
    $query = POST('query');
    // Security OJO
    InventorySearch::insert($conn, $type, $subtype, $match, $list, $query);
}
$matches = InventorySearch::get_matches($conn);
if ($type != "" && $subtype != "") {
    // Security OJO
    $rule = InventorySearch::get_rule($conn, $type, $subtype);
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title> <?php 
echo $title;
?>
 </title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<link rel="stylesheet" type="text/css" href="../style/style.css"/>