Changeset 149 for www/jidelna/tisk.php


Ignore:
Timestamp:
Feb 15, 2009, 8:07:45 PM (16 years ago)
Author:
george
Message:
  • Upraveno: Přepracována stránka jídelny.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • www/jidelna/tisk.php

    r4 r149  
    11<?php
    2 include_once('../style.php');
    32include_once('../global.php');
    43echo('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
     
    1615//echo('Dnes je '.HumanDate(date('Y-m-d')).'<br>');
    1716echo('<table height="99%" width="100%" align="center" border="1" cellspacing="0" cellpadding="3">');
    18 $Date = explode('-',$_GET['date']);
     17$Date = explode('-', $_GET['date']);
    1918echo('<tr><td style="border-bottom-style: solid; border-bottom-color: black; border-bottom-width: 2;" colspan="2">
    20 <table cellspacing="0" cellpadding="0" width="100%"><tr><td width="50%"><strong>DATUM:</strong> '.HumanDate($_GET['date']).' - '.HumanDate(date('Y-m-d',mktime(0,0,0,$Date[1],$Date[2],$Date[0])+4*86400)).'</td>
     19<table cellspacing="0" cellpadding="0" width="100%"><tr><td width="50%"><strong>DATUM:</strong> '.HumanDate($_GET['date']).' - '.HumanDate(date('Y-m-d',mktime(0, 0, 0, $Date[1], $Date[2], $Date[0]) + 4 * 86400)).'</td>
    2120<td align="right">CENY SMLUVNÍ</td></tr></table>
    2221<div align="center" style="font-size: xx-large;">&bdquo;JÍDELNA NA KOPEČKU&rdquo;</div>
    2322<div align="center" style="font-size: x-large;">JÍDELNÍČEK</div>
    2423</td></tr>');
    25 $Date = explode('-',$_GET['date']);
    26 $Time2 = mktime(0,0,0,$Date[1],$Date[2],$Date[0]);
    27 for($I=0; $I< 5; $I++)
     24$Date = explode('-', $_GET['date']);
     25$Time2 = mktime(0, 0, 0, $Date[1], $Date[2], $Date[0]);
     26for($I = 0; $I < 5; $I++)
    2827{
    29   $Time = $Time2 + $I*86400;
    30   $Date = date('Y-m-d',$Time);
    31   $DayOfWeek = date('w',$Time);
    32   $DbResult = $Database->select('meals','*','date="'.$Date.'"');
     28  $Time = $Time2 + $I * 86400;
     29  $Date = date('Y-m-d', $Time);
     30  $DayOfWeek = date('w', $Time);
     31  $DbResult = $Database->select('Meals', '*', 'Date="'.$Date.'"');
    3332  $Row = $DbResult->fetch_array();
    3433  echo('<tr><td style="border-style: solid; border-color: black; border-width: 2; font-size: xx-large;" width="10%">'.$DnyZkratky[$DayOfWeek].'</td><td style="font-size: x-large; border-style: solid; border-color: black; border-width: 2;" width="90%">');
    35   if($Row['status']==0) echo('&nbsp;<br><br>&nbsp;');
    36   if($Row['status']==1) echo('Polévka: '.$Row['soap'].'<br><br>'.$Row['meal']);
    37   else if(($Row['status']==2) or ($Row['status']==3))
     34  if($Row['Status'] == 0) echo('&nbsp;<br><br>&nbsp;');
     35  if($Row['Status'] == 1) echo('Polévka: '.$Row['Soup'].'<br><br>'.$Row['Meal']);
     36  else if(($Row['status'] == 2) or ($Row['status'] == 3))
    3837  {
    39     echo('<br>'.$Status[$Row['status']].'<br>&nbsp;');
     38    echo('<br>'.$Status[$Row['Status']].'<br>&nbsp;');
    4039  }
    4140  echo('</td></tr>');
    4241}
    43 $DbResult = $Database->select('meals_info','*');
     42$DbResult = $Database->select('MealsInfo','*');
    4443$Row = $DbResult->fetch_array();
    4544echo('<tr><td style="border-top-style: solid; border-top-color: black; border-top-width: 2;" colspan="2"><table cellspacing="0" cellpadding="0" width="100%"><tr><td width="50%"><strong>JÍDLA PŘIPRAVIL: BAROŇOVÁ L.</strong></td>
    4645<td align="right"><strong>PROVOZOVATEL:</strong></td></tr></table>
    4746<br>
    48 <strong>CENA JEDNOHO MENU JE '.$Row['price'].' Kč</strong></td></tr>');
     47<strong>CENA JEDNOHO MENU JE '.$Row['Price'].' Kč</strong></td></tr>');
    4948//echo('<tr><td colspan="2">dd</td></tr>');
    5049echo('</table>');
Note: See TracChangeset for help on using the changeset viewer.