NodeJS repozitar pro 4.J pro rok 2025/2026
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

69 lines
2.0 KiB

<?php
$title = "Rezervační systém Hotelu";
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>
<?= $title; ?>
</title>
</head>
<body>
<h1><?= $title; ?></h1>
<form action="vysledek.php" method="get">
<label for="jmeno">Jméno:</label>
<input type="text" id="jmeno" name="jmeno" require>
<br>
<label for="prijmeni">Příjmení:</label>
<input type="text" id="prijmeni" name="prijmeni" require>
<br>
<label for="adresa">Adresa:</label>
<input type="text" id="adresa" name="adresa" require>
<br>
<label for="pocet_osob">Počet osob:</label>
<input type="number" id="pocet_osob" name="pocet_osob" min="1" value="1" require>
<br>
<label for="pocet_noci">Počet nocí:</label>
<input type="number" id="pocet_noci" name="pocet_noci" min="1" value="1" require>
<br>
<button type="submit">Odeslat Rezervaci</button>
</form>
<?php if (isset($_GET["jmeno"])): ?>
<h3>Jméno <?= $_GET["jmeno"]; ?></h3>
<?php endif; ?>
<?php if (isset($_GET["prijmeni"])): ?>
<h3>Příjmení: <?= $_GET["prijmeni"]; ?></h3>
<?php endif; ?>
<?php if (isset($_GET["adresa"])): ?>
<h3>Adresa: <?= $_GET["adresa"]; ?></h3>
<?php endif; ?>
<?php if (isset($_GET["pocet_osob"])): ?>
<h3>Počet osob <?= $_GET["pocet_osob"]; ?></h3>
<?php endif; ?>
<?php if (isset($_GET["pocet_noci"])): ?>
<h3>Počet nocí <?= $_GET["pocet_noci"]; ?></h3>
<?php endif; ?>
<?php if (isset($_GET["pocet_osob"]) && isset($_GET["pocet_noci"])): ?>
<h3>Celková cená <?= $_GET["pocet_osob"] * $_GET["pocet_noci"] * 200; ?></h3>
<?php endif; ?>
<!-- Ukázka isset -->
<?php if (isset($_GET["mesto"])): ?>
<h3>MESTO <?= $_GET["mesto"]; ?></h3>
<?php endif; ?>
</body>
</html>