示例#1
0
function getJourSemaine($index)
{
    return jourSemaine()[$index - 1];
}
示例#2
0
文件: saisie.php 项目: ktla/locan-2
echo SITE_ROOT . "public/img/icons/apercu.png";
?>
" />
                        Aper&ccedil;u</a> 
                </li>
            </ul></div>
        <div id="onglet1" class="onglet" style="display: block;height: 80%">
            <div id = 'emplois-content'><table id="tableEmplois" class='dataTable'>
                <thead><th>Jour</th><th>D&eacute;but</th><th>Fin</th><th>Enseignant</th><th>Mati&egrave;re</th><th></th></thead>
                <tbody></tbody>
                </table></div>
            <div id="ajout-emplois-dialog" class="dialog" title="S&eacute;lectionner les horaires">
                <span><label>Jour de la semaine:</label>
                    <select name = 'jour' style="width:100%;"><?php 
$i = 1;
$jours = jourSemaine();
foreach ($jours as $j) {
    echo "<option value = '{$i}'>{$j}</option>";
    $i++;
}
?>
                    </select>
                </span>
                 <span><label>Mati&egrave;res : </label><select name = 'enseignement' style="width: 100%"></select></span>
                <span style="width: 150px; float: left;"><label>Heure d&eacute;but:</label><input type="text" name="heuredebut" size="15"  id="heuredebut" /></span>
                <span style="width: 150px;float: left;"><label>Heure fin:</label><input type="text" name="heurefin" id="heurefin" size="15" /></span>
               
            </div>
        </div>
        <div id="onglet2" class="onglet" style="display: none;height: 80%">
            <div id="apercu-content"></div>
示例#3
0
$corps = '<table style="text-align:center" cellpadding="2">
              <tr style="font-weight:bold">
			       <th border="0.5"  width ="' . $col[0] . '%">DATES</th>
			        <th border="0.5" width ="' . $col[1] . '%">LUNDI</th>
				<th border="0.5"  width ="' . $col[2] . '%">MARDI</th>
				<th border="0.5"  width ="' . $col[3] . '%">MERCREDI</th>
				<th border="0.5"  width ="' . $col[4] . '%">JEUDI</th>
				<th border="0.5" width ="' . $col[5] . '%">VENDREDI</th>
				<th border="0.5"  width ="' . $col[6] . '%">SAMEDI</th>
             </tr>';
$date = $datedebut;
$d = new DateFR();
while ($date <= $datefin) {
    $d->setSource($date);
    $corps .= '<tr><td border="0.5">' . $d->getDate() . ' ' . $d->getMois(3) . ' ' . $d->getYear() . '</td>';
    $semaine = jourSemaine();
    for ($i = 1; $i < 7; $i++) {
        $absents = enseignantAbsentByPeriode($date, $absences);
        $corps .= '<td border="0.5">';
        foreach ($absents as $abs) {
            $corps .= substr($abs['NOM'], 0, 10) . "<br/>";
        }
        $corps .= "</td>";
        # Passer au jour suivant
        $date = date("Y-m-d", strtotime("+1 day", strtotime($date)));
        $d->setSource($date);
    }
    $date = date("Y-m-d", strtotime("+1 day", strtotime($date)));
    $d->setSource($date + 1);
    $corps .= '</tr>';
}