From 2c1f8da1c7e33a642ec4c739137253fdfd5a8982 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fernando=20M=C3=A9ndez?= <45081533+FerMdez@users.noreply.github.com> Date: Tue, 25 May 2021 18:03:22 +0200 Subject: [PATCH] Delete index copy.php --- purchase/index copy.php | 148 ---------------------------------------- 1 file changed, 148 deletions(-) delete mode 100644 purchase/index copy.php diff --git a/purchase/index copy.php b/purchase/index copy.php deleted file mode 100644 index 02eadce..0000000 --- a/purchase/index copy.php +++ /dev/null @@ -1,148 +0,0 @@ -FilmData($_GET["film"]); - if($film){ - $tittle = $film->getTittle(); - - $cinemas = $filmDAO->getCinemas($_GET["film"]); - if(!empty($cinemas)){ - $cinemasNames = new ArrayIterator(array()); - $cinemasIDs = new ArrayIterator(array()); - foreach($cinemas as $key=>$value){ - $cinemasIDs[$key] = $value->getId(); - $cinemasNames[$key] = $value->getName(); - } - $cinemasIT = new MultipleIterator(MultipleIterator::MIT_KEYS_ASSOC); - $cinemasIT->attachIterator($cinemasIDs, "cID"); - $cinemasIT->attachIterator($cinemasNames, "NAME"); - - $cinemasListHTML = ''; - } else { - $cinemasListHTML = ''; - } - - $fiml_id = $film->getId(); - $cinema_id = $value["cID"]; - - $cinemaDAO = new Cinema_DAO("complucine"); - $sessions = $cinemaDAO->getSessions($value["cID"]); - if(!empty($sessions)){ - $sessionsDates = new ArrayIterator(array()); - $sessionsStarts = new ArrayIterator(array()); - $sessionsHalls = new ArrayIterator(array()); - $sessionsIDs = new ArrayIterator(array()); - foreach($sessions as $key=>$value){ - $sessionsIDs[$key] = $value->getId(); - $sessionsDates[$key] = date_format(date_create($value->getDate()), 'j-n-Y'); - $sessionsHalls[$key] = $value->getIdhall(); - $sessionsStarts[$key] = $value->getStartTime(); - } - $sessionsIT = new MultipleIterator(MultipleIterator::MIT_KEYS_ASSOC); - $sessionsIT->attachIterator($sessionsIDs, "sID"); - $sessionsIT->attachIterator($sessionsDates, "DATE"); - $sessionsIT->attachIterator($sessionsHalls, "HALL"); - $sessionsIT->attachIterator($sessionsStarts, "HOUR"); - - $sessionsListHTML = ''; - } else { - $sessionsListHTML = ''; - } - - $session_id = $value["sID"]; - $hall_id = $value["HALL"]; - $date_ = $value["DATE"]; - $hour_ = $value["HOUR"]; - - //Reply: Depends on whether the purchase is to be made from a selected movie or a cinema. - $reply = '
-

Película seleccionada: '.str_replace('_', ' ', $tittle).'


-
'.$tittle.'
-

Duración: '.$film->getDuration().' minutos

-

Idioma: '.$film->getLanguage().'

-
-
-

Seleccione un Cine y una Sesión


-

Cines

- '.$cinemasListHTML.'
-

Sesiones

- '.$sessionsListHTML.' -
- '; - } else { - $reply = '

No existe la película.

'; - $pay = false; - } - } else if(isset($_GET["cinema"])) { - $reply = '

ESTAMOS TRABAJANDO EN ELLO

'; - $pay = false; - } else { - $reply = '

No se ha encontrado película ni cine.

'; - $pay = false; - } - - - //Pay button: - if($pay){ - $pay = '
- - - - - - - -
'; - } - //Page-specific content: - $section = ' -
-
-
- '.$reply.' -
-
- '.$pay.' -
-
-
- '; - - //General page content: - require RAIZ_APP.'/HTMLtemplate.php'; -?>