generated from francesco/deploy-dinamico
169 lines
6.2 KiB
PHP
169 lines
6.2 KiB
PHP
<?php
|
|
if (isset($_GET["sorgente"])) {
|
|
highlight_file("process_candidatura.php");
|
|
exit;
|
|
}
|
|
|
|
if ($_SERVER["REQUEST_METHOD"] === "GET") {
|
|
die("<code>Questa pagina blocca il metodo GET, compila prima il modulo!</code>");
|
|
}
|
|
?>
|
|
|
|
<!DOCTYPE html>
|
|
<html lang="it">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Candidatura confermata</title>
|
|
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&display=swap" rel="stylesheet">
|
|
|
|
<link rel="stylesheet" href="candidatura.css">
|
|
<link rel="icon" type="image/png" href="favicon.png" sizes="96x96" />
|
|
<script src="https://kit.fontawesome.com/c2497a668c.js" crossorigin="anonymous" type="text/javascript"></script>
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<header>
|
|
<div class="container">
|
|
<div class="logo">
|
|
<img src="logo.png" alt="McDonald's">
|
|
<h3>McDonald's</h3>
|
|
</div>
|
|
</div>
|
|
</header>
|
|
|
|
<div class="hero">
|
|
<div class="overlay">
|
|
<div class="container">
|
|
<h1>Invio confermato!</h1>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="page">
|
|
<section class="container">
|
|
<h2>Grazie per aver inviato la tua candidatura!</h2>
|
|
|
|
<p>Ecco i dati che abbiamo ricevuto (array <code>$_POST</code>): </p>
|
|
|
|
<div class="post-data">
|
|
|
|
<?php
|
|
if (!isset($_POST)) {
|
|
// Dati mancanti
|
|
?>
|
|
<h2>Invio dati del form non completo, riprova!</h2>
|
|
<?php
|
|
} else {
|
|
|
|
// Controllo la presenza di ogni variabile
|
|
|
|
echo "<p><strong>Nome</strong><br>";
|
|
if (isset($_POST["nome"])) {
|
|
// Sanitizzazione input necessaria
|
|
$var = htmlspecialchars($_POST["nome"]);
|
|
echo $var;
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>E-mail</strong><br>";
|
|
if (isset($_POST["email"])) {
|
|
// Sanitizzazione input necessaria
|
|
$var = htmlspecialchars($_POST["email"]);
|
|
echo $var;
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>Esperienza</strong><br>";
|
|
if (isset($_POST["esperienza"])) {
|
|
// Sanitizzazione input necessaria
|
|
$var = htmlspecialchars($_POST["esperienza"]);
|
|
echo $var;
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>Competenze</strong><br>";
|
|
if (isset($_POST["competenze"])) {
|
|
// Sanitizzazione input necessaria
|
|
foreach ($_POST["competenze"] as $competenza) {
|
|
echo htmlspecialchars($competenza);
|
|
echo "<br>";
|
|
}
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>File allegato</strong><br>";
|
|
if (isset($_POST["curriculum"]) || isset($_FILES["curriculum"])) {
|
|
// Sanitizzazione necessaria solo per salvataggio del file, con permessi di esecuzione bloccati
|
|
echo "<i>Nome</i>: " . $_FILES["curriculum"]['name'];
|
|
echo "<br><i>Tipo di file</i>: " . $_FILES['curriculum']['type'];
|
|
echo "<br><i>Directory temporanea</i>: " . $_FILES['curriculum']['tmp_name'];
|
|
echo "<br><i>Errori riscontrati</i>: " . $_FILES['curriculum']['error'];
|
|
echo "<br><i>Dimensione</i>: " . $_FILES['curriculum']['size'] . " B";
|
|
echo "<br><br>Utilizzato l'array di PHP <code>$_FILES</code> e l'attributo <code>enctype=\"multipart/form-data\"</code> al modulo";
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>Lettera di presentazione</strong><br>";
|
|
if (isset($_POST["lettera"])) {
|
|
// Sanitizzazione input necessaria
|
|
$var = htmlspecialchars($_POST["lettera"]);
|
|
echo $var;
|
|
} else {
|
|
echo "<code>NON PRESENTE</code>";
|
|
}
|
|
echo "</p>";
|
|
|
|
echo "<p><strong>Privacy accettata</strong><br>";
|
|
if (isset($_POST["accetto"])) {
|
|
echo "Si";
|
|
} else {
|
|
echo "No";
|
|
}
|
|
echo "</p>";
|
|
}
|
|
?>
|
|
|
|
</div>
|
|
|
|
</section>
|
|
|
|
<section class="container">
|
|
<p>Verrai molto presto ricontattato da uno dei nostri addetti!<br><a
|
|
href="https://www.adaptivesecurity.com/blog/mcdonalds-password-data-breach" target="_blank">
|
|
Per approfondire <i class="fa-solid fa-arrow-up-right-from-square"></i></a></p>
|
|
</section>
|
|
|
|
<section class="container">
|
|
<div class="buttons">
|
|
<a class="button" onclick="history.back();">Torna indietro</a>
|
|
<a class="button" href="process_candidatura.php?sorgente">Leggi sorgente</a>
|
|
<a class="button" href="../">Torna all'inizio</a>
|
|
</div>
|
|
</section>
|
|
</div>
|
|
|
|
<footer>
|
|
<div class="container">
|
|
Realizzato da Francesco Giuseppe Mancuso - classe 5E - www.francescomancuso.it
|
|
</div>
|
|
</footer>
|
|
|
|
</body>
|
|
|
|
</html>
|