-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconfirm.php
More file actions
executable file
·42 lines (32 loc) · 808 Bytes
/
confirm.php
File metadata and controls
executable file
·42 lines (32 loc) · 808 Bytes
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
38
39
40
41
42
<?php
/**
* Payment Page
*
* - Choose Packages
* - Calculate Total
* - Confirm
*
*/
include 'app.php';
if(!isset($_SESSION['cart']) || !$logined){
header("Location: index.php");
die();
}
if(isset($_POST) && isset($_POST['seats']) && !empty($_POST['seats']))
$_SESSION['cart']['seats'] = explode(',', $_POST['seats']);
$cart = $_SESSION['cart'];
$movie = Movies::retrieveByPK($cart['id']);
$packages = Packages::all();
//date choices (maximum 7 days)
$dates = array();
for($i=0; $i<=6; $i++){
$dates[] = array(
'value' => date('Y-m-d', time()+($i*86400)),
'show' => date('j M', time()+($i*86400))
);
}
//time choices
$times = array('11:00', '13:00', '15:00', '17:00', '19:00', '21:00', '23:00');
//halls
$halls = Halls::all();
include 'views/confirm.php';