24 lines
634 B
PHP
24 lines
634 B
PHP
<?php
|
|
exit();
|
|
// ist veraltet, muss noch angepasst werden.
|
|
session_start();
|
|
$strLoginName=(isset($_SESSION['user'])) ? $_SESSION['user'] : "" ;
|
|
$boolLogin = (!empty($strLoginName));
|
|
if (!$boolLogin) {
|
|
header("Location: login.php");
|
|
}
|
|
|
|
date_default_timezone_set('UTC');
|
|
|
|
$strSQL="ALTER TABLE location ADD COLUMN defect INTEGER";
|
|
$db->exec($strSQL);
|
|
|
|
$db->exec("CREATE TABLE IF NOT EXISTS user(
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
username TEXT,
|
|
passwordhash TEXT,
|
|
lastlogin TEXT DEFAULT CURRENT_TIMESTAMP,
|
|
created_at TEXT DEFAULT CURRENT_TIMESTAMP
|
|
)");
|
|
|
|
header("Location: configuration.php"); |