<?php
/*
    CREATIVE COMMONS - Attribution-No Derivative Works 3.0 Germany:
    - You may not alter, transform, or build upon this work.
    - Dieses Werk darf nicht bearbeitet oder in anderer Weise verändert werden.
*/
  $ArtistSelector = '';
  $ThisFile = 'calendar.php';

  $Path = str_replace('\\','/', __FILE__);
  $Path = str_replace('calendar/'.$ThisFile, '', $Path);

  include_once($Path."gigkalender.ini.php");
  include_once($Path."includes/error_reporting.php");
  include_once($Path."functions/standard.php");
  include_once($Path."includes/frontend_language_selector.php");

  $GigID = "";
  $Timestamp = "";
  foreach ($_REQUEST as $key => $value)
    {
      if (get_magic_quotes_gpc()) $$key = stripslashes($value);
      else $$key = $value;
    }
  foreach ($_POST as $key => $value)
  {
    if (get_magic_quotes_gpc()) $$key = stripslashes($value);
    else $$key = $value;
  }

  echo '<div class="GigKalender">';
  if ( $GigID!="" OR $Timestamp!="" )
  {
    $GigDetailsShown = true;
    $SetupFrontendCalendarGigDetailsShowEmptyAttributes  = getSetup('SetupFrontendCalendarGigDetailsShowEmptyAttributes');
    $SetupFrontendCalendarGigDetailsDateFormat   = getSetup('SetupFrontendCalendarGigDetailsDateFormat');
    include_once ($Path."calendar/showGigDetails.php");
  }
  else
  {
    $GigDetailsShown = false;
    //$XXX = false;
    $SetupFrontendCalendarPeriodSelector = getSetup('SetupFrontendCalendarPeriodSelector');
    $SetupFrontendCalendarSelector = getSetup('SetupFrontendCalendarSelector');
    $SetupFrontendCalendarDateFormat = getSetup('SetupFrontendCalendarDateFormat');
    $SetupFrontendCalendarGigDetailsURL = getSetup('SetupFrontendCalendarGigDetailsURL');
    if ( $SetupFrontendCalendarSelector == 'list') include ($Path."calendar/list.php");
    elseif ( $SetupFrontendCalendarSelector == 'table') include ($Path."calendar/table.php");
  }
  echo '</div>';
?>
