Subversion Repositories eFlore/Archives.herbiers

Rev

Rev 21 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 21 Rev 23
Line 17... Line 17...
17
// |                                                                                                      |
17
// |                                                                                                      |
18
// | You should have received a copy of the GNU Lesser General Public                                     |
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                                  |
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                            |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
21
// +------------------------------------------------------------------------------------------------------+
21
// +------------------------------------------------------------------------------------------------------+
22
// CVS : $Id: hb_rss.php,v 1.9 2007-08-22 14:34:04 jp_milcent Exp $
22
// CVS : $Id: hb_rss.php,v 1.10 2007-11-23 10:04:12 jp_milcent Exp $
23
/**
23
/**
24
* Générateur de flux RSS pour les Herbiers 
24
* Générateur de flux RSS pour les Herbiers 
25
*
25
*
26
*@package bazar
26
*@package bazar
27
//Auteur original :
27
//Auteur original :
28
*@author        Florian SCHMITT <florian@ecole-et-nature.org>
28
*@author        Florian SCHMITT <florian@ecole-et-nature.org>
29
*@author        Jean-Pascal MILCENT <jpm@tela-botanica.org>
29
*@author        Jean-Pascal MILCENT <jpm@tela-botanica.org>
30
*
30
*
31
*@copyright     Tela-Botanica 2000-2006
31
*@copyright     Tela-Botanica 2000-2006
32
*@version       $Revision: 1.9 $ $Date: 2007-08-22 14:34:04 $
32
*@version       $Revision: 1.10 $ $Date: 2007-11-23 10:04:12 $
33
// +------------------------------------------------------------------------------------------------------+
33
// +------------------------------------------------------------------------------------------------------+
34
*/
34
*/
Line 35... Line 35...
35
 
35
 
36
//==================================== LES FLUX RSS==================================
36
//==================================== LES FLUX RSS==================================
Line 135... Line 135...
135
		switch ($type) {
135
		switch ($type) {
136
			case 'equipe' :
136
			case 'equipe' :
137
				$aso_infos['title'] = $ligne['titre_prenom'].' '.$ligne['titre_nom'];
137
				$aso_infos['title'] = $ligne['titre_prenom'].' '.$ligne['titre_nom'];
138
				$aso_infos['link'] = str_replace('&', '&amp;', sprintf($url, 32, $ligne['id_org'], $ligne['id_equipe']));
138
				$aso_infos['link'] = str_replace('&', '&amp;', sprintf($url, 32, $ligne['id_org'], $ligne['id_equipe']));
139
				$aso_infos['description'] = 'Modifié par '.$ligne['prenom'].' '.$ligne['nom'].' le '.$ligne['date_derniere_modif'];
139
				$aso_infos['description'] = 'Modifié par '.$ligne['prenom'].' '.$ligne['nom'].' le '.$ligne['date_derniere_modif'];
140
				$aso_infos['pubdate'] = strftime('%d %b %Y %H:%M:%S GMT', $ligne['date_derniere_modif']);		
140
				$aso_infos['pubdate'] = strftime('%d %b %Y %H:%M:%S GMT', strtotime($ligne['date_derniere_modif']));		
141
				break;
141
				break;
142
			case 'note' :
142
			case 'note' :
143
				if ($ligne['titre'] != '') {
143
				if ($ligne['titre'] != '') {
144
					$aso_infos['title'] = $ligne['titre'];
144
					$aso_infos['title'] = $ligne['titre'];
145
				} else {
145
				} else {
Line 164... Line 164...
164
		$aso_infos = array();
164
		$aso_infos = array();
165
		$aso_infos['title'] = 'Flux RSS : '.$flux;
165
		$aso_infos['title'] = 'Flux RSS : '.$flux;
166
		$GLOBALS['_HERBIER_']['rss']['url']->addQueryString('type', $flux);
166
		$GLOBALS['_HERBIER_']['rss']['url']->addQueryString('type', $flux);
167
		$aso_infos['link'] = str_replace('&', '&amp;', $GLOBALS['_HERBIER_']['rss']['url']->getURL());
167
		$aso_infos['link'] = str_replace('&', '&amp;', $GLOBALS['_HERBIER_']['rss']['url']->getURL());
168
		$aso_infos['description'] = 'Flux RSS sur les '.$flux.'s.';
168
		$aso_infos['description'] = 'Flux RSS sur les '.$flux.'s.';
169
		$aso_infos['pubdate'] = strftime('%d %b %Y %H:%M:%S GMT', strtotime(str_replace('$', '', str_replace('Date: ', '', '$Date: 2007-08-22 14:34:04 $'))));
169
		$aso_infos['pubdate'] = strftime('%d %b %Y %H:%M:%S GMT', strtotime(str_replace('$', '', str_replace('Date: ', '', '$Date: 2007-11-23 10:04:12 $'))));
170
		$tab_infos[] = $aso_infos;
170
		$tab_infos[] = $aso_infos;
171
	} 
171
	} 
172
}
172
}
173
// En fonction, de l'appel depuis Papyrus ou pas nous affichons du XML ou du XHTML
173
// En fonction, de l'appel depuis Papyrus ou pas nous affichons du XML ou du XHTML
174
if (!defined('PAP_VERSION')) {
174
if (!defined('PAP_VERSION')) {
Line 255... Line 255...
255
	return $xml;
255
	return $xml;
256
}
256
}
257
/* +--Fin du code ----------------------------------------------------------------------------------------+
257
/* +--Fin du code ----------------------------------------------------------------------------------------+
258
*
258
*
259
* $Log: not supported by cvs2svn $
259
* $Log: not supported by cvs2svn $
-
 
260
* Revision 1.9  2007-08-22 14:34:04  jp_milcent
-
 
261
* Correction problème : même nom de fonction que dans Bazar...
-
 
262
*
260
* Revision 1.8  2006-11-07 17:28:21  jp_milcent
263
* Revision 1.8  2006-11-07 17:28:21  jp_milcent
261
* Correction concernant les urls des collections.
264
* Correction concernant les urls des collections.
262
*
265
*
263
* Revision 1.7  2006/10/31 16:03:42  jp_milcent
266
* Revision 1.7  2006/10/31 16:03:42  jp_milcent
264
* Correction rendu xhtml dans Papyrus.
267
* Correction rendu xhtml dans Papyrus.