Exemple #1
0
}
if (isset($_POST["calc"]) and $_POST["calc"] != "") {
    $flag2 = True;
    $calc = $_POST['calc'];
    foreach ($calc as $value) {
        if ($value == "GSE") {
            $gse = True;
        } elseif ($value == "energy") {
            $elev = True;
        }
    }
}
if ($flag1 && $flag2) {
    printResults($_POST["atom"], $box, $sho, $pos, $gse, $elev);
}
printBottom();
//~~~~~~~~~~~~~~~~~~~~~~~~~~~BEGIN FUNCTIONS~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//Need to add javascript in printBottom() to check for correct submission?
function printForm()
{
    $script = $_SERVER['PHP_SELF'];
    //Maybe put a box around the form so it looks cool?
    print <<<FORM
  <div id="content">
  <div id="c2">
  <p><b> Select your Parameters </b></p>
    <form method="POST" action={$script} id="formContent">
    <p> Atom: <select name="atom">
      <option selected="selected"> H </option>
      <option> He </option>
      <option> Li </option>
Exemple #2
0
function editDBCreate()
{
    if (!$_SESSION["logged"]) {
        exit("No way");
    }
    printHead();
    generateTypes();
    generateGoods();
    printContentBegin();
    printClassPanelBegin();
    printClassMenu();
    printClassPanel();
    printClassPanelEnd();
    printGoodsPanelBegin();
    printGoodsMenu();
    printGoodsPanel();
    printGoodsPanelEnd();
    printContentEnd();
    printBottom();
}