Subversion Repositories Applications.bazar

Rev

Rev 335 | Rev 380 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
30 ddelon 1
<?php
2
/*vim: set expandtab tabstop=4 shiftwidth=4: */
3
// +------------------------------------------------------------------------------------------------------+
4
// | PHP version 4.1                                                                                      |
5
// +------------------------------------------------------------------------------------------------------+
6
// | Copyright (C) 2004 Tela Botanica (accueil@tela-botanica.org)                                         |
7
// +------------------------------------------------------------------------------------------------------+
8
// | This library is free software; you can redistribute it and/or                                        |
9
// | modify it under the terms of the GNU Lesser General Public                                           |
10
// | License as published by the Free Software Foundation; either                                         |
11
// | version 2.1 of the License, or (at your option) any later version.                                   |
12
// |                                                                                                      |
13
// | This library is distributed in the hope that it will be useful,                                      |
14
// | but WITHOUT ANY WARRANTY; without even the implied warranty of                                       |
15
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU                                    |
16
// | Lesser General Public License for more details.                                                      |
17
// |                                                                                                      |
18
// | You should have received a copy of the GNU Lesser General Public                                     |
19
// | License along with this library; if not, write to the Free Software                                  |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
21
// +------------------------------------------------------------------------------------------------------+
379 jp_milcent 22
// CVS : $Id: bazar.fonct.cal.php,v 1.24.2.2 2008-03-13 17:42:07 jp_milcent Exp $
30 ddelon 23
/**
24
*
25
* Fonctions calendrier du module bazar
26
*
27
*@package bazar
28
//Auteur original :
29
*@author        David Delon <david.delon@clapas.net>
30
//Autres auteurs :
31
*@copyright     Tela-Botanica 2000-2004
379 jp_milcent 32
*@version       $Revision: 1.24.2.2 $ $Date: 2008-03-13 17:42:07 $
30 ddelon 33
// +------------------------------------------------------------------------------------------------------+
34
*/
35
 
36
// +------------------------------------------------------------------------------------------------------+
37
// |                                            ENTETE du PROGRAMME                                       |
38
// +------------------------------------------------------------------------------------------------------+
225 neiluj 39
 
55 florian 40
require_once PAP_CHEMIN_RACINE.'api/pear/Calendar/Month/Weekdays.php';
41
require_once PAP_CHEMIN_RACINE.'api/pear/Calendar/Day.php';
42
require_once PAP_CHEMIN_RACINE.'api/pear/Calendar/Decorator.php';
30 ddelon 43
 
44
// +------------------------------------------------------------------------------------------------------+
45
// |                                           LISTE de FONCTIONS                                         |
46
// +------------------------------------------------------------------------------------------------------+
47
 
48
// Classe Utilitaire pour Calendrier
49
class DiaryEvent extends Calendar_Decorator {
205 jp_milcent 50
	var $entry = array();
51
	function DiaryEvent($calendar)
52
	{
30 ddelon 53
		Calendar_Decorator::Calendar_Decorator($calendar);
54
	}
205 jp_milcent 55
	function setEntry($entry)
56
	{
57
		$this->entry[] = $entry;
30 ddelon 58
 
59
	}
205 jp_milcent 60
	function getEntry()
61
	{
30 ddelon 62
		return $this->entry;
63
	}
64
}
65
 
66
 
42 ddelon 67
// $type : calendrier
68
// $type : calendrier_appplette
258 alexandre_ 69
function GestionAffichageCalendrier($arguments = array(), $type = 'calendrier') {
290 alexandre_ 70
	$script = '';
258 alexandre_ 71
	// recuperation des arguments de l applette
72
	$balise = isset ($arguments[0]) ? $arguments[0] : '';
73
    $tab_arguments = $arguments;
335 alexandre_ 74
	if (is_string ($tab_arguments)) {
75
		$tab_arguments = substr($tab_arguments, 1);
76
	} else {
77
		unset($tab_arguments[0]);
78
	}
258 alexandre_ 79
	if (is_array($tab_arguments)) {
80
	    foreach($tab_arguments as $argument) {
81
	    	if ($argument != '') {
82
		    	$tab_parametres = explode('=', $argument, 2);
267 florian 83
		    	if (is_array($tab_parametres)) {
84
		    		$options[$tab_parametres[0]] =
85
		    		(isset($tab_parametres[1])? trim($tab_parametres[1], '"') : '') ;
86
		    	}
258 alexandre_ 87
	    	}
88
	    }
89
	}
90
 
91
    if (!isset($options['template'])) {
92
		$options['template'] = BAZ_CHEMIN_SQUELETTE.BAZ_SQUELETTE_DEFAUT;
93
	} else {
94
		if (file_exists(BAZ_CHEMIN_SQUELETTE.$options['template'])) {
95
			$options['template'] = BAZ_CHEMIN_SQUELETTE.$options['template'];
96
		}
97
	}
98
 
208 jp_milcent 99
	$retour = '';
225 neiluj 100
 
30 ddelon 101
	$url = $GLOBALS['_GEN_commun']['url'] ;
205 jp_milcent 102
	$db =& $GLOBALS['_GEN_commun']['pear_db'] ;
103
	$auth =& $GLOBALS['_GEN_commun']['pear_auth'] ;
30 ddelon 104
 
279 alexandre_ 105
	// Nettoyage de l'url de la query string
106
	$chaine_url = $url->getQueryString();
107
	$tab_params = explode('&amp;', $chaine_url);
108
	if (count($tab_params) == 0) {
109
		$tab_params = explode('&', $chaine_url);
110
	}
111
	foreach ($tab_params as $param) {
112
		$tab_parametre = explode('=', $param);
113
		$url->removeQueryString($tab_parametre[0]);
114
	}
115
 
30 ddelon 116
	if (!isset($_GET['y'])) {
117
		$_GET['y'] = date('Y');
118
	}
119
 
120
	if (!isset($_GET['m'])) {
121
		$_GET['m'] = date('m');
122
	}
123
 
124
	// 	Construction Mois en Cours
125
	$month = new Calendar_Month_Weekdays($_GET['y'],$_GET['m']);
126
 
205 jp_milcent 127
	$curStamp = $month->getTimeStamp();
128
	$url->addQueryString('y', date('Y',$curStamp));
129
	$url->addQueryString('m', date('n',$curStamp));
130
	$url->addQueryString('d', date('j',$curStamp));
30 ddelon 131
	$cur = $url->getUrl();
279 alexandre_ 132
 
133
	// Gestion de l'affichage des titres des évènements
134
	if (isset($_GET['ctt']) && $_GET['ctt'] == '1') {
135
		$url->addQueryString('tt', '0');
136
		if (isset($_GET['tt']) && $_GET['tt'] == '0') {
137
			$url->addQueryString('tt', '1');
138
		}
139
		$tc_lien = $url->getUrl();
140
	} else {
141
		$url->addQueryString('tt', '0');
142
		if (isset($_GET['tt']) && $_GET['tt'] == '0') {
143
			$url->addQueryString('tt', '1');
144
		}
145
		$url->addQueryString('ctt', '1');
146
		$tc_lien = $url->getUrl();
147
	}
148
	$url->removeQueryString('ctt');
149
	$url->removeQueryString('tt');
150
	$tc_txt = 'Afficher les titres complets des évènements';
151
	if (isset($_GET['tt']) && $_GET['tt'] == '0') {
152
		$tc_txt = 'Tronquer les titres des évènements';
153
		$url->addQueryString('tt', $_GET['tt']);
154
	}
30 ddelon 155
 
156
	// Navigation
157
	$prevStamp = $month->prevMonth(true);
205 jp_milcent 158
	$url->addQueryString('y', date('Y',$prevStamp));
159
	$url->addQueryString('m', date('n',$prevStamp));
160
	$url->addQueryString('d', date('j',$prevStamp));
30 ddelon 161
	$prev = $url->getUrl();
205 jp_milcent 162
 
30 ddelon 163
	$nextStamp = $month->nextMonth(true);
205 jp_milcent 164
	$url->addQueryString('y', date('Y',$nextStamp));
165
	$url->addQueryString('m', date('n',$nextStamp));
166
	$url->addQueryString('d', date('j',$nextStamp));
30 ddelon 167
	$next = $url->getUrl();
205 jp_milcent 168
 
279 alexandre_ 169
	// Suppression du paramêtre de troncage des titres
170
	$url->removeQueryString('tt');
171
 
205 jp_milcent 172
	$fr_month = array(	"1"=>BAZ_JANVIER,"2"=>BAZ_FEVRIER,"3"=>BAZ_MARS,"4"=>BAZ_AVRIL,"5"=>BAZ_MAI,"6"=>BAZ_JUIN,
173
						"7"=>BAZ_JUILLET,"8"=>BAZ_AOUT,"9"=>BAZ_SEPTEMBRE,"10"=>BAZ_OCTOBRE,"11"=>BAZ_NOVEMBRE,"12"=>BAZ_DECEMBRE);
30 ddelon 174
 
279 alexandre_ 175
	// Titre
176
	if ($type == 'calendrier') {
177
		// Ajout des styles du bazar
178
		if (defined('PAP_VERSION')) { //si on est dans Papyrus
179
			GEN_stockerStyleExterne( 'bazar_interne', 'client/bazar/bazar.interne.css');
180
			GEN_stockerFichierScript('domLib', '/api/js/domtooltip/domLib.js');
181
			GEN_stockerFichierScript('domTT', '/api/js/domtooltip/domTT.js');
182
			// DomToolTip
183
			$script = 'var domTT_styleClass = "niceTitle";'."\n";
184
			$script .= 'function nicetitleDecorator(el) {'."\n";
185
			$script .= '	var result = el.title;'."\n";
186
			$script .= '	result = result.replace(new RegExp("\n", "g"), "<br />");'."\n";
187
			$script .= '	if (el.href) {'."\n";
188
			$script .= '		result += "<p>" + el.href + "</p>";'."\n";
189
			$script .= '	}'."\n";
190
			$script .= '	return result;'."\n";
191
			$script .= '}'."\n";
192
			$script .= 'domTT_replaceTitles(nicetitleDecorator);'."\n";
193
			GEN_stockerCodeScript('var domTT_styleClass = "niceTitle";'."\n");
194
		}
195
		$retour .= '<div id="cal_entete">';
196
		$retour .= '<span class="cal_navigation">';
197
		$retour .= '<a id="cal_precedent_lien" href="'.$prev.'" title="Allez au mois précédent"><img id="cal_precedent_img" src="client/bazar/images/cal_precedent.png" alt="&lt;&lt;"/></a>';
198
		$retour .= '&nbsp;&nbsp;';
199
		$retour .= '<span id="cal_encadre_mois_courrant"><a id="cal_mois_courrant" href="'.$cur.'">';
200
		$retour .= $fr_month[(date('n',$curStamp))];
201
		$retour .= '&nbsp;';
202
		$retour .= (date('Y',$curStamp));
203
		$retour .= '</a></span>';
204
		$retour .= '&nbsp;&nbsp;';
205
		$retour .= '<a id="cal_suivant_lien" href="'.$next.'" title="Allez au mois suivant"><img id="cal_suivant_img" src="client/bazar/images/cal_suivant.png" alt="&gt;&gt;"/></a>';
206
		$retour .= '</span>';
207
		$retour .= '<h1 id="cal_titre"><img id="cal_titre_img" src="client/bazar/images/cal_titre.png" alt="Calendrier"/></h1>';
208
		$retour .= '</div>';
209
 
210
		$retour .= '<p>'.'<a href="'.$tc_lien.'">'.$tc_txt.'</a>'.'</p>';
211
	} else {
212
		// Appel du template
213
		ob_start();
214
		include $options['template'];
215
		$retour .= ob_get_contents();
216
		ob_end_clean();
217
	}
42 ddelon 218
	// Vue Mois calendrier ou vue applette
219
 
279 alexandre_ 220
	if ((!isset($_GET['id_fiche']) && $type == 'calendrier') || ($type == 'calendrier_applette')){
290 alexandre_ 221
//		trigger_error('ICI', E_USER_NOTICE);
30 ddelon 222
		// Recherche evenement de la periode selectionnée
279 alexandre_ 223
		$ts_jour_fin_mois = $month->nextMonth('timestamp');
224
		$ts_jour_debut_mois = $month->thisMonth('timestamp');;
225
	    $requete_evenements = 	"SELECT DISTINCT bf_id_fiche, bf_titre, bf_lieu_evenement, DAY(bf_date_debut_evenement) AS bf_jour_debut_evenement, bf_date_debut_evenement, bf_date_fin_evenement, bf_description ".
185 jp_milcent 226
								"FROM bazar_fiche, bazar_nature ".
279 alexandre_ 227
								"WHERE bf_date_debut_evenement < '".date('Y-m-d', $ts_jour_fin_mois)."' ".
228
								"AND bf_date_fin_evenement >= '".date('Y-m-d', $ts_jour_debut_mois)."' ".
185 jp_milcent 229
								"AND bf_ce_nature = bn_id_nature ".
213 jp_milcent 230
								"AND bn_id_nature IN (".BAZ_NUM_ANNONCE_CALENDRIER.") ".
263 alexandre_ 231
								"AND bf_statut_fiche = 1 ".
232
								"ORDER BY bf_jour_debut_evenement";
225 neiluj 233
 
30 ddelon 234
	   	$resultat_evenement = $db->query($requete_evenements);
225 neiluj 235
 
279 alexandre_ 236
	    (DB::isError($resultat_evenement)) ? trigger_error(BOG_afficherErreurSql(__FILE__, __LINE__, $resultat_evenement->getMessage(), $requete_evenements), E_USER_WARNING) : '';
237
 
238
		$selection = array();
239
		$evenements = array();
240
		$annee = date('Y', $curStamp);
241
		$mois = date('m', $curStamp);
242
		$tablo_jours = array();
30 ddelon 243
	    while ($ligne_evenements = $resultat_evenement->fetchRow(DB_FETCHMODE_OBJECT)) {
279 alexandre_ 244
			list($annee_debut, $mois_debut, $jour_debut) = explode('-', $ligne_evenements->bf_date_debut_evenement);
245
			list($annee_fin, $mois_fin, $jour_fin) = explode('-', $ligne_evenements->bf_date_fin_evenement);
30 ddelon 246
 
279 alexandre_ 247
			$Calendrier = new Calendar($annee_debut, $mois_debut, $jour_debut);
248
			$ts_jour_suivant = $Calendrier->thisDay('timestamp');
249
			$ts_jour_fin = mktime(0,0,0,$mois_fin, $jour_fin, $annee_fin);
30 ddelon 250
 
279 alexandre_ 251
	    	if ($ts_jour_suivant < $ts_jour_fin) {
252
				//echo "$ts_jour_suivant-";
253
				$naviguer = true;
254
				while ($naviguer) {
255
					// Si le jours suivant est inférieur à la date de fin, on continue...
256
					if ($ts_jour_suivant <= $ts_jour_fin) {
257
						// Si le jours suivant est inférieur à la date de fin du mois courrant, on continue...
258
						if ($ts_jour_suivant < $ts_jour_fin_mois) {
259
							$cle_j = date('Y-m-d', $ts_jour_suivant);
260
							if (!isset($tablo_jours[$cle_j])) {
261
								$tablo_jours[$cle_j]['Calendar_Day'] = new Calendar_Day(date('Y', $ts_jour_suivant),date('m', $ts_jour_suivant), date('d', $ts_jour_suivant));
262
								$tablo_jours[$cle_j]['Diary_Event'] = new DiaryEvent($tablo_jours[$cle_j]['Calendar_Day']);
379 jp_milcent 263
								trigger_error('<pre>la :'.print_r($cle_j, true).'</pre>', E_USER_WARNING);
279 alexandre_ 264
							}
265
							$tablo_jours[$cle_j]['Diary_Event']->setEntry($ligne_evenements);
266
 
267
							$ts_jour_suivant = $Calendrier->nextDay('timestamp');
268
							//echo "ici$ts_jour_suivant-";
269
							$Calendrier->setTimestamp($ts_jour_suivant);
270
							//echo "la".$Calendrier->thisDay('timestamp')."-";
271
						} else {
272
							$naviguer = false;
273
						}
274
					} else {
275
						$naviguer = false;
276
					}
277
				}
278
	    	} else {
279
				$curday_ymd = $annee.$mois.$ligne_evenements->bf_jour_debut_evenement;
379 jp_milcent 280
				$cle_j = $annee.'-'.$mois.'-'.sprintf('%02s', $ligne_evenements->bf_jour_debut_evenement);
279 alexandre_ 281
				if (!isset($tablo_jours[$cle_j])) {
282
					$tablo_jours[$cle_j]['Calendar_Day'] = new Calendar_Day($annee, $mois, $ligne_evenements->bf_jour_debut_evenement);
283
					$tablo_jours[$cle_j]['Diary_Event'] = new DiaryEvent($tablo_jours[$cle_j]['Calendar_Day']);
379 jp_milcent 284
					trigger_error('<pre>ici :'.print_r($cle_j, true).'</pre>', E_USER_WARNING);
279 alexandre_ 285
				}
286
				$tablo_jours[$cle_j]['Diary_Event']->setEntry($ligne_evenements);
287
	    	}
30 ddelon 288
		}
379 jp_milcent 289
 
279 alexandre_ 290
		// Add the decorator to the selection
291
		foreach ($tablo_jours as $jour) {
379 jp_milcent 292
			$selection[] = $jour['Diary_Event'];
279 alexandre_ 293
		}
379 jp_milcent 294
 
30 ddelon 295
		// Affichage Calendrier
296
		$month->build($selection);
279 alexandre_ 297
		if ($type == 'calendrier') {
298
			$retour.= '<table class="calendrier">'.
299
				'<colgroup>'.
300
					'<col class="cal_lundi"/>'.
301
					'<col class="cal_mardi"/>'.
302
					'<col class="cal_mercredi"/>'.
303
					'<col class="cal_jeudi"/>'.
304
					'<col class="cal_vendredi"/>'.
305
					'<col class="cal_samedi"/>'.
306
					'<col class="cal_dimanche"/>'.
307
				'</colgroup>'.
308
				'<thead>'.
309
			 	"<tr>
42 ddelon 310
 
311
			  <th> ". BAZ_LUNDI ."</th>
312
			  <th> ". BAZ_MARDI ."</th>
313
			  <th> ". BAZ_MERCREDI ."</th>
314
			  <th> ". BAZ_JEUDI ."</th>
315
			  <th> ". BAZ_VENDREDI ."</th>
316
			  <th> ". BAZ_SAMEDI ."</th>
317
			  <th> ". BAZ_DIMANCHE ."</th>
318
			 </tr>
279 alexandre_ 319
			 ".'</thead>'.'<tbody>';
320
		} else {
321
			$retour.= '<table class="calendrier_applette">'.
322
				'<colgroup>'.
323
					'<col class="cal_lundi"/>'.
324
					'<col class="cal_mardi"/>'.
325
					'<col class="cal_mercredi"/>'.
326
					'<col class="cal_jeudi"/>'.
327
					'<col class="cal_vendredi"/>'.
328
					'<col class="cal_samedi"/>'.
329
					'<col class="cal_dimanche"/>'.
330
				'</colgroup>'.
331
				'<thead>'.
332
			 "<tr>
42 ddelon 333
 
334
			  <th> ". BAZ_LUNDI_COURT ."</th>
335
			  <th> ". BAZ_MARDI_COURT ."</th>
336
			  <th> ". BAZ_MERCREDI_COURT ."</th>
337
			  <th> ". BAZ_JEUDI_COURT ."</th>
338
			  <th> ". BAZ_VENDREDI_COURT ."</th>
339
			  <th> ". BAZ_SAMEDI_COURT ."</th>
340
			  <th> ". BAZ_DIMANCHE_COURT ."</th>
341
			 </tr>
279 alexandre_ 342
			 ".'</thead>'.'<tbody>';
42 ddelon 343
		}
30 ddelon 344
 
345
		$todayStamp=time();
346
		$today_ymd=date('Ymd',$todayStamp);
279 alexandre_ 347
 
30 ddelon 348
		// Other month : mois
349
		while ($day = $month->fetch() ) {
279 alexandre_ 350
			$dayStamp = $day->thisDay(true);
351
			$day_ymd = date('Ymd',$dayStamp);
352
			if ( $day->isEmpty() ) {
353
				$class = "cal_ma other_month";
354
			} else {
355
				if (($day_ymd < $today_ymd)) {
356
					$class= "cal_mp previous_month";
357
				} else {
358
					 if ($day_ymd == $today_ymd) {
359
					 	$class= "cal_jc current_day";
360
					 } else {
361
						$class="cal_mc current_month";
362
					 }
30 ddelon 363
				}
279 alexandre_ 364
			}
30 ddelon 365
 
279 alexandre_ 366
			$url->addQueryString ('y', date('Y',$dayStamp));
367
			$url->addQueryString ('m', date('n',$dayStamp));
368
			$url->addQueryString ('d', date('j',$dayStamp));
369
			$link = $url->getUrl();
370
 
371
			// isFirst() to find start of week
372
			if ($day->isFirst()) {
373
				$retour.= ( "<tr>\n" );
374
			}
375
			if ($type == 'calendrier') {
376
				$retour.= "<td class=\"".$class."\">".'<span class="cal_j">'.$day->thisDay().'</span>'."\n";
377
				if ($day->isSelected() ) {
378
					$evenements = $day->getEntry();
379
					$evenements_nbre = count($evenements);
380
					$evenemt_xhtml = '';
381
					while ($ligne_evenement = array_pop($evenements)) {
382
						$id_fiches = array();
383
						$id_fiches[] = $ligne_evenement->bf_id_fiche;
42 ddelon 384
						$url->addQueryString ('id_fiches',$id_fiches);
30 ddelon 385
						$link = $url->getUrl();
279 alexandre_ 386
 
387
						if (!isset($_GET['tt']) || (isset($_GET['tt']) && $_GET['tt'] == '1')) {
388
							$titre_taille = strlen($ligne_evenement->bf_titre);
389
							$titre = ($titre_taille > 20)?substr($ligne_evenement->bf_titre, 0, 20).'...':$ligne_evenement->bf_titre;
390
						} else {
391
							$titre = $ligne_evenement->bf_titre;
392
						}
393
						$evenemt_xhtml .= '<li class="tooltip" title="'.$ligne_evenement->bf_titre.'"><a class="cal_evenemt" href="'.$link.'">'.$titre.'</a></li>'."\n";
42 ddelon 394
						$url->removeQueryString ('id_fiches');
30 ddelon 395
					}
279 alexandre_ 396
					if ($evenements_nbre > 0) {
397
						$retour .= '<ul class="cal_evenemt_liste">';
398
						$retour .= $evenemt_xhtml;
399
						$retour .= '</ul>';
400
					}
30 ddelon 401
				}
279 alexandre_ 402
			} else {
297 alexandre_ 403
				$lien_date= "<td class=\"".$class."\">".$day->thisDay();
279 alexandre_ 404
				if ($day->isSelected() ) {
405
					$evenements=$day->getEntry();
406
					$id_fiches=array();
407
					while ($ligne_evenement=array_pop($evenements)) {
408
						$id_fiches[]=$ligne_evenement->bf_id_fiche;
409
					}
410
					$url->addQueryString ('id_fiches',$id_fiches);
411
					$link = $url->getUrl();
412
					$lien_date= "<td class=\"".$class."\"><a href=\"".$link."\">".$day->thisDay()."</a>\n";
413
					$url->removeQueryString ('id_fiches');
414
				}
415
				$retour.=$lien_date;
30 ddelon 416
			}
279 alexandre_ 417
			$retour.= ( "</td>\n" );
30 ddelon 418
 
279 alexandre_ 419
			// isLast() to find end of week
420
			if ( $day->isLast() ) {
421
				$retour.= ( "</tr>\n" );
422
			}
42 ddelon 423
		}
279 alexandre_ 424
			$retour.= "</tbody></table>";
425
	}
426
	$retour.= '<script type="text/javascript">//<![CDATA['."\n".$script.'//]]></script>'."\n";
427
	// Vue detail
428
 
429
	if ((isset($_GET['id_fiches']))) {
430
		// Ajout d'un titre pour la page avec la date
431
		$jours = array ('lundi', 'mardi', 'mercredi', 'jeudi', 'vendredi', 'samedi', 'dimanche') ;
432
		$mois = array ('janvier', 'février', 'mars', 'avril', 'mai', 'juin', 'juillet', 'août', 'septembre',
433
						'octobre', 'novembre', 'décembre') ;
434
		$timestamp = strtotime ($_GET['y'].'/'.$_GET['m'].'/'.$_GET['d']) ;
225 neiluj 435
 
279 alexandre_ 436
		$GLOBALS['_PAPYRUS_']['rendu']['CONTENU_NAVIGATION'] = '';
437
		$GLOBALS['_PAPYRUS_']['rendu']['CONTENU_TETE'] = '';
438
		$GLOBALS['_PAPYRUS_']['rendu']['CONTENU_CORPS'] = '<h1>'.$jours[date('w', $timestamp)].
439
						' '.$_GET['d'].' '.$mois[$_GET['m']-1].' '.$_GET['y'].'</h1>' ;
440
		$GLOBALS['_PAPYRUS_']['rendu']['CONTENU_CORPS'] .= baz_voir_fiches(0,$_GET['id_fiches'] );
297 alexandre_ 441
 
279 alexandre_ 442
		$GLOBALS['_GEN_commun']['info_menu'] = '';
297 alexandre_ 443
 
444
		// Un lien pour retourner au calendrier
445
		$url->removeQueryString('id_fiches');
446
		$url->removeQueryString('y');
447
		$url->removeQueryString('m');
448
		$url->removeQueryString('d');
449
		$GLOBALS['_PAPYRUS_']['rendu']['CONTENU_PIED'] = '<div class="retour"><a href="'.$url->getURL().'">Retour au calendrier</a></div>';
279 alexandre_ 450
	}
451
 
452
	// Nettoyage de l'url
453
	$url->removeQueryString('id_fiches');
454
	$url->removeQueryString('y');
455
	$url->removeQueryString('m');
456
	$url->removeQueryString('d');
297 alexandre_ 457
 
458
 
279 alexandre_ 459
	return $retour;
460
}
30 ddelon 461
?>