Add files via upload

This commit is contained in:
Fernando Méndez 2021-05-24 13:38:19 +02:00 committed by GitHub
parent 5732adfec9
commit 6625d9787a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9,12 +9,14 @@
include_once($prefix.'assets/php/includes/cinema.php');
include_once($prefix.'assets/php/includes/session.php');
$pay = true;
$film = null;
$cinemas = [];
$sessions = [];
if(isset($_GET["film"])){
$filmDAO = new Film_DAO("complucine");
$film = $filmDAO->FilmData($_GET["film"]);
if($film){
$tittle = $film->getTittle();
$cinemas = $filmDAO->getCinemas($_GET["film"]);
@ -79,8 +81,6 @@
$session_id = $value["sID"];
$hall_id = $value["HALL"];
}
//Reply: Depends on whether the purchase is to be made from a selected movie or a cinema.
$reply = '<div class="column left">
@ -97,7 +97,22 @@
'.$sessionsListHTML.'
</div>
';
} else {
$reply = '<h1>No existe la película.</h1>';
$pay = false;
}
}
//Pay button:
if($pay){
$pay = '<form action="confirm.php" method="post">
<input type="hidden" name="film_id" id="film_id" value='.$fiml_id.' />
<input type="hidden" name="cinema_id" id="cinema_id" value='.$cinema_id.' />
<input type="hidden" name="session_id" id="session_id" value='.$session_id.' />
<input type="hidden" name="hall_id" id="hall_id" value='.$hall_id.' />
<input type="submit" id="submit" value="Pagar" />
</form>';
}
//Page-specific content:
$section = '<!-- Purchase -->
<section id="purchase">
@ -106,13 +121,7 @@
'.$reply.'
</section>
<section class="code purchase">
<form action="confirm.php" method="post">
<input type="hidden" name="film_id" id="film_id" value='.$fiml_id.' />
<input type="hidden" name="cinema_id" id="cinema_id" value='.$cinema_id.' />
<input type="hidden" name="session_id" id="session_id" value='.$session_id.' />
<input type="hidden" name="hall_id" id="hall_id" value='.$hall_id.' />
<input type="submit" id="submit" value="Pagar" />
</form>
'.$pay.'
</section>
</div>
</section>