Advertisement
showtimeiNK

Untitled

May 28th, 2015
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.92 KB | None | 0 0
  1. <?php
  2. /*
  3.  * Brinck Bill
  4.  * T3IF2
  5.  * bribi093@school.lu
  6.  */
  7.  
  8. //Include the config.inc.php file
  9. require_once("config.inc.php");
  10.  
  11. //Check if the user is logged in
  12. if(isset($_SERVER["REMOTE_USER"]) && $_SERVER["REMOTE_USER"] != "") {
  13.  
  14.     //Check if the $_POST variable fAll is set
  15.     if (isset($_POST["fAll"])) {
  16.         //Call function getMinValueOfSensor and output the return value
  17.         echo functions::getMinValueOfSensor($db, null, null, null, 1);
  18.     } else {
  19.         //Store values in variables and sanitize them
  20.         $date = functions::sanitize_string_for_html($_POST["fDate"], $db, 0);
  21.         $start = functions::sanitize_string_for_html($_POST["fTimeStart"], $db, 0);
  22.         $end = functions::sanitize_string_for_html($_POST["fTimeEnd"], $db, 0);
  23.  
  24.         //Call function getMinValueOfSensor and output the return value
  25.         echo functions::getMinValueOfSensor($db, $date, $start, $end, 0);
  26.     }
  27. }
  28. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement