-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmehm-formular.php
37 lines (33 loc) · 1.13 KB
/
mehm-formular.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<!DOCTYPE html>
<html lang="de">
<head>
<link href="styles/formular.css" rel="stylesheet">
<meta charset="UTF-8">
<title> Dein Mehm - upload </title>
<?php include("includes/meta.php"); ?>
<style>
:root {
--banner-top: #b167eb;
--banner-bottom: #4bd8f6;
}
</style>
</head>
<body>
<?php include("includes/header.php"); ?>
<main class="container">
<section class="paper">
<?php $target_dir = "uploads/";
$target_file = $target_dir . basename($_FILES["mDatei"]["name"]);
$uploadOk = 1;
$imageFileType = strtolower(pathinfo($target_file,PATHINFO_EXTENSION));
if (move_uploaded_file($_FILES["mDatei"]["tmp_name"], $target_file)) {
echo "<h1> Viele Dank für deine Einsedung der Kategorie ". $_POST["mKategorie"]. "!</h1> <br><p class=\"response\"> Die Datei ". htmlspecialchars( basename( $_FILES["mDatei"]["name"])). " wurde erfolgreich hochgeladen. </p>";
} else {
echo "<h1> Tut uns Leid, es ist ein Fehler aufgetreten. Bitte versuche es erneut!</h1>";}
?>
</section>
</main>
<?php include("includes/footer.php"); ?>
<?php include("includes/bottom-navigation.php"); ?>
</body>
</html>