Example #1
0
<?php

/**
 * Default Template
 *
 * @autor Dora Peña
 * @email   dora.pena@periferia-it.com
 * @date    November 2013
 */
// No direct access to this file
defined('_JEXEC') or die;
$discountPath = JURI::root() . 'modules/mod_discountflights/js/';
$discountDoc = JFactory::getDocument();
$discountDoc->addScript($discountPath . 'load-tabs.js');
$tabs = moddiscountflightsHelper::getDiscountFlightsTabs();
$discountFlights = moddiscountflightsHelper::getDiscountFlights($tabs);
$discountRegions = moddiscountflightsHelper::getRegions();
$module_aaws_qs = JModuleHelper::getModule('mod_aaws_qs');
$module_aaws_qs_params = new JRegistry();
$module_aaws_qs_params->loadString($module_aaws_qs->params);
$max_flights = 100;
$max_regions = 100;
$discountOffsetDays = (int) $module_aaws_qs_params->get('offset_days');
$discountCheckinDate = strtotime('+' . $discountOffsetDays . ' day', strtotime(date('Y-m-d')));
$discountCheckinDate = date('Y-m-d', $discountCheckinDate);
/*-----------------------------------------------------------------------------------------------------*/
/*MICOD
En éste lugar capturo las URL con parametros GET para realizar la búsqueda de ofertas de vuelo.
Solo funciona con URL externas (Pubilicades).*/
$id = $_GET["id_vuelo"];
if (isset($id)) {