Example #1
0
            $a_day = (int) $abc[2];
            $a_hour = (int) $abc[3];
            $a_minute = (int) $abc[4];
            $a_room = (int) $abc[5];
            $_GET['view'] = (int) $abc[6];
            $time_end = mktime($a_hour, $a_minute, 0, $a_month, $a_day, $a_year);
            addValue('time_end', $time_end);
            addValueArray('room_id', splittIDs($a_room));
            addValue('time_start', $time_end - $time_end_after_start);
        }
    }
    if (isset($_GET['time_start']) && is_numeric($_GET['time_start'])) {
        addValue('time_start', (int) $_GET['time_start']);
    }
    if (isset($_GET['time_end']) && is_numeric($_GET['time_end'])) {
        addValue('time_end', (int) $_GET['time_end']);
    }
    if (isset($_GET['user_assigned'])) {
        if (is_array($_GET['user_assigned'])) {
            addValueArray('user_assigned', $_GET['user_assigned']);
        } else {
            addValueArray('user_assigned', splittIDs($_GET['user_assigned']));
        }
    }
    if (isset($_GET['room']) && is_numeric($_GET['room'])) {
        // Single room
        addValueArray('room_id', array((int) $_GET['room'] => (int) $_GET['room']));
    }
}
/*
if($entry_add)
Example #2
0
<?php

require_once 'ja.php';
writeHello();
writeMsg('hello');
writeMsg('okdoei');
writeMsgTo('Robin', 'ja');
writeMsgTo('Robin');
$outcome = addValue(5, 7);
echo 'The outcome of 5+7 = ' . $outcome . '<br/>';
$outcome = calcRect(5, 7);
echo 'The area of a rectangle of 5 and 7 is ' . $outcome . '<br/>';
BMI();
include "../secure/session.php";
session_start();
//sessionInit();
$_SESSION['attempt'] = 0;
include "XMLGen.php";
$file = 'default.xml';
$subhandle = fopen($file, "w");
fwrite($subhandle, '');
fclose($subhandle);
$sql = "SELECT * FROM photo";
$result = mysql_query($sql);
openXML($file);
openSlideshow($file);
openOption($file);
openInteraction($file);
addValue($file, "<speed>10</speed>");
closeInteraction($file);
closeOption($file);
while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
    addImage($file, "../match_photo/" . basename($row['path']), $row['title']);
}
closeSlideshow($file);
$sql = "SELECT * FROM system";
$result = mysql_query($sql) or die("Parse Error");
$row = mysql_fetch_array($result, MYSQL_ASSOC);
if ($row['safe_mode'] == 1) {
    header("Location: ../login.php");
}
?>
<!DOCTYPE html>
<html>
                        $thisone['mva_eks'] = true;
                    } else {
                        $thisone['mva_eks'] = false;
                    }
                    $thisone['mva'] = (double) $thisone['mva'] / 100;
                    ${$field['var']}[$i] = $thisone;
                }
            }
            ${$field}['var'] = invoiceContentNumbers(${$field}['var']);
            addValueArray($field['var'], ${$field}['var']);
            break;
        case 'resourcenum':
            if (isset($_POST[$field['var']])) {
                ${$field}['var'] = $_POST[$field['var']];
            }
            addValue($field['var'], ${$field}['var']);
            break;
        case 'empty':
        case 'submit1':
        case 'submit2':
        case 'submit3':
            // Ignore
            break;
        default:
            echo 'System error! New input field is detected, <b>' . $field['var'] . '</b>. This must be made in <b>' . __FILE__ . '</b>. System have halted.';
            //echo '<br><br>';
            //print_r($_POST);
            exit;
    }
}
/* Checking the times */