Ignore:
Timestamp:
02/28/06 20:23:38 (19 years ago)
Author:
Daniela Dorner
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/datacenter/db/runinfo.php

    r7527 r7546  
    319319    }
    320320
    321     function PrintForm($_GET, $db)
     321    function PrintForm($_GET, $host, $user, $pw, $db)
    322322    {
    323323        printf("<center>\n");
     
    372372        printf(" <table>\n");
    373373        printf("  <tr><td>\n");
    374         PrintPullDown($db, "RunType",     "fRunTypeName",     "fRunTypeKEY", "Run type");
    375         printf("  </td><td>\n");
    376         PrintPullDown($db, "Source",      "fSourceName",      "fSourceKEY", "Source Name");
    377         printf("  </td><td>\n");
    378         PrintPullDown($db, "HvSettings",  "fHvSettingsName",  "fHvSettingsKEY", "HV Settings");
    379         printf("  </td><td>\n");
    380         PrintPullDown($db, "L1TriggerTable", "fL1TriggerTableName", "fL1TriggerTableKEY", "L1 Trigger Table");
     374        PrintPullDown($host, $user, $pw, $db, "RunType",     "fRunTypeName",     "fRunTypeKEY", "Run type");
     375        printf("  </td><td>\n");
     376        PrintPullDown($host, $user, $pw, $db, "Source",      "fSourceName",      "fSourceKEY", "Source Name");
     377        printf("  </td><td>\n");
     378        PrintPullDown($host, $user, $pw, $db, "HvSettings",  "fHvSettingsName",  "fHvSettingsKEY", "HV Settings");
     379        printf("  </td><td>\n");
     380        PrintPullDown($host, $user, $pw, $db, "L1TriggerTable", "fL1TriggerTableName", "fL1TriggerTableKEY", "L1 Trigger Table");
    381381        printf("  </td></tr><tr><td>\n");
    382         PrintPullDown($db, "TestFlag",  "fTestFlagName",  "fTestFlagKEY", "Test Flag");
    383         printf("  </td><td>\n");
    384         PrintPullDown($db, "Project",     "fProjectName",     "fProjectKEY", "Project Name");
    385         printf("  </td><td>\n");
    386         PrintPullDown($db, "DiscriminatorThresholdTable",  "fDiscriminatorThresholdTableName",  "fDiscriminatorThresholdTableKEY", "DT Table");
    387         printf("  </td><td>\n");
    388         PrintPullDown($db, "L2TriggerTable", "fL2TriggerTableName", "fL2TriggerTableKEY", "L2 Trigger Table");
     382        PrintPullDown($host, $user, $pw, $db, "TestFlag",  "fTestFlagName",  "fTestFlagKEY", "Test Flag");
     383        printf("  </td><td>\n");
     384        PrintPullDown($host, $user, $pw, $db, "Project",     "fProjectName",     "fProjectKEY", "Project Name");
     385        printf("  </td><td>\n");
     386        PrintPullDown($host, $user, $pw, $db, "DiscriminatorThresholdTable",  "fDiscriminatorThresholdTableName",  "fDiscriminatorThresholdTableKEY", "DT Table");
     387        printf("  </td><td>\n");
     388        PrintPullDown($host, $user, $pw, $db, "L2TriggerTable", "fL2TriggerTableName", "fL2TriggerTableKEY", "L2 Trigger Table");
    389389        printf("  </td></tr><tr><td>\n");
    390         PrintPullDown($db, "ExcludedFDA", "fExcludedFDAName", "fExcludedFDAKEY", "Exclusions");
    391         printf("  </td><td>\n");
    392         PrintPullDown($db, "LightConditions",  "fLightConditionsName",  "fLightConditionsKEY", "Light Conditions");
    393         printf("  </td><td>\n");
    394         PrintPullDown($db, "CalibrationScript",  "fCalibrationScriptName",  "fCalibrationScriptKEY", "Cal Script");
    395         printf("  </td><td>\n");
    396         PrintPullDown($db, "TriggerDelayTable",  "fTriggerDelayTableName",  "fTriggerDelayTableKEY", "Trigger Delay Table");
     390        PrintPullDown($host, $user, $pw, $db, "ExcludedFDA", "fExcludedFDAName", "fExcludedFDAKEY", "Exclusions");
     391        printf("  </td><td>\n");
     392        PrintPullDown($host, $user, $pw, $db, "LightConditions",  "fLightConditionsName",  "fLightConditionsKEY", "Light Conditions");
     393        printf("  </td><td>\n");
     394        PrintPullDown($host, $user, $pw, $db, "CalibrationScript",  "fCalibrationScriptName",  "fCalibrationScriptKEY", "Cal Script");
     395        printf("  </td><td>\n");
     396        PrintPullDown($host, $user, $pw, $db, "TriggerDelayTable",  "fTriggerDelayTableName",  "fTriggerDelayTableKEY", "Trigger Delay Table");
    397397        printf("  </td></tr><tr><td>\n");
    398         PrintPullDown($db, "MagicNumber", "fMagicNumberName", "fMagicNumberKEY", "Magic Number");
     398        PrintPullDown($host, $user, $pw, $db, "MagicNumber", "fMagicNumberName", "fMagicNumberKEY", "Magic Number");
    399399        printf(" </td></tr></table>\n");
    400400
     
    402402
    403403        if (empty($_GET["fStartDate"]))
    404             $timemin = GetMin("fRunStart", "RunData", $db);
     404            $timemin = GetMin("fRunStart", "RunData", $host, $user, $pw, $db);
    405405        else
    406406            $timemin = $_GET["fStartDate"];
    407407
    408408        if (empty($_GET["fStopDate"]))
    409             $timemax = GetMax("fRunStart", "RunData", $db);
     409            $timemax = GetMax("fRunStart", "RunData", $host, $user, $pw, $db);
    410410        else
    411411            $timemax = $_GET["fStopDate"];
     
    427427
    428428        if (empty($_GET["fRunMin"]))
    429             $min = GetMin("fRunNumber", "RunData", $db);
     429            $min = GetMin("fRunNumber", "RunData", $host, $user, $pw, $db);
    430430        else
    431431            $min = $_GET["fRunMin"];
    432432
    433433        if (empty($_GET["fRunMax"]))
    434             $max = GetMax("fRunNumber", "RunData", $db);
     434            $max = GetMax("fRunNumber", "RunData", $host, $user, $pw, $db);
    435435        else
    436436            $max = $_GET["fRunMax"];
     
    477477    }
    478478
    479     function PrintPage($html, $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs)
     479    function PrintPage($html, $host, $user, $pw, $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs)
    480480    {
    481         $db_id = mysql_connect("hercules.astro.uni-wuerzburg.de", "MAGIC", "d99swMT!");
     481        $db_id = mysql_connect($host, $user, $pw);
    482482        if ($db_id==FALSE)
    483483        {
     
    519519        header("Content-Disposition: attachment; filename=query-result.txt");
    520520
    521         PrintPage("0", $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
     521        PrintPage("0", $host, $user, $pw, $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
    522522    }
    523523    else
     
    529529        InitGet($_GET);
    530530        if (empty($_GET["fPrintTable"]))
    531             PrintForm($_GET, $db);
     531            PrintForm($_GET, $host, $user, $pw, $db);
    532532
    533533        if ($environment==0)
     
    536536        {
    537537            if (empty($_GET["fPrintTable"]))
    538                 PrintPage("1", $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
     538                PrintPage("1", $host, $user, $pw, $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
    539539            else
    540                 PrintPage("2", $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
     540                PrintPage("2", $host, $user, $pw, $db, $alias, $rightalign, $checkwhere, $checkgroup, $checkstatusgroup, $needs);
    541541        }
    542542
Note: See TracChangeset for help on using the changeset viewer.