fixes
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
<?php
|
||||
exit();
|
||||
|
||||
date_default_timezone_set('UTC');
|
||||
|
||||
$db = new SQLite3($dbFilename);
|
||||
require("../config.db.php");
|
||||
|
||||
$db->exec("CREATE TABLE IF NOT EXISTS location(
|
||||
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
* E-Mail: info@hupfeld-software.de
|
||||
* Version: 1.0
|
||||
* Datum: 18.05.2021
|
||||
* zuletzt geändert: 18.02.2024
|
||||
******************************** */
|
||||
|
||||
session_start();
|
||||
@@ -14,7 +15,8 @@
|
||||
if (!$boolLogin) {
|
||||
header("Location: login.php");
|
||||
}
|
||||
$dbFilename="../db/locations.db";
|
||||
|
||||
require("../config.db.php");
|
||||
require ("../config.php");
|
||||
|
||||
// Set headers to make the browser download the results as a csv file
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
* E-Mail: info@hupfeld-software.de
|
||||
* Version: 1.0
|
||||
* Datum: 18.05.2021
|
||||
* zuletzt geändert: 18.02.2024
|
||||
******************************** */
|
||||
|
||||
session_start();
|
||||
@@ -14,7 +15,6 @@
|
||||
if (!$boolLogin) {
|
||||
header("Location: login.php");
|
||||
}
|
||||
$dbFilename="../db/locations.db";
|
||||
require ("../config.php");
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
|
||||
@@ -1,11 +1,20 @@
|
||||
<?php
|
||||
/** *****************************
|
||||
* Ideenmelder
|
||||
* Autor: Walter Hupfeld, Hamm
|
||||
* E-Mail: info@hupfeld-software.de
|
||||
* Version: 1.0
|
||||
* Datum: 18.05.2021
|
||||
* zuletzt geändert: 18.02.2024
|
||||
*/
|
||||
|
||||
session_start();
|
||||
$strLoginName=(isset($_SESSION['user'])) ? $_SESSION['user'] : "" ;
|
||||
$boolLogin = (!empty($strLoginName));
|
||||
if (!$boolLogin) {
|
||||
header("Location: login.php");
|
||||
}
|
||||
$dbFilename="../db/locations.db";
|
||||
require_once("../config.db.php");
|
||||
require ("../config.php");
|
||||
require ("../lib/geocoding.php");
|
||||
$boolRefresh = (isset($_GET['refresh']) & $_GET['refresh']==1);
|
||||
|
||||
@@ -36,7 +36,6 @@
|
||||
|
||||
$stmt = $db->prepare("SELECT * FROM files where loc_id = :loc_id");
|
||||
$stmt->bindValue(":loc_id", $numDelete, PDO::PARAM_INT);
|
||||
$result = $stmt->execute();
|
||||
|
||||
if ($row = $result->fetch(PDO::FETCH_ASSOC)) {
|
||||
$strFilename = $row['filename'];
|
||||
@@ -64,10 +63,11 @@
|
||||
if($_GET['csrf'] !== $_SESSION['csrf_token']) {
|
||||
die("Ungültiger Token");
|
||||
}
|
||||
|
||||
$numDelete=(int)$_GET['delfid'];
|
||||
$stmt = $db->prepare("SELECT * FROM files where id = :id");
|
||||
$stmt->bindValue(":id", $numDelete, SQLITE3_TEXT);
|
||||
$result = $stmt->execute();
|
||||
$stmt->bindParam(':id', $id);
|
||||
//$result = $stmt->execute();
|
||||
if ($row=$result->fetch(PDO::FETCH_ASSOC)) {
|
||||
$strFilename = $row['filename'];
|
||||
$strFilename = $uploaddir . $strFilename;
|
||||
@@ -76,6 +76,7 @@
|
||||
$stmt = $db->prepare("DELETE FROM files WHERE id= :id");
|
||||
$stmt->bindValue(":id",$numDelete);
|
||||
$stmt->execute();
|
||||
|
||||
}
|
||||
|
||||
if (isset($_GET['showmap'])) {
|
||||
|
||||
Reference in New Issue
Block a user