Subversion Repositories Applications.papyrus

Compare Revisions

Ignore whitespace Rev 1203 → Rev 1204

/trunk/papyrus/applettes/syndication/syndication.php
21,7 → 21,7
// | along with Foobar; if not, write to the Free Software |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
// +------------------------------------------------------------------------------------------------------+
// CVS : $Id: syndication.php,v 1.2 2006-12-13 17:20:51 jp_milcent Exp $
// CVS : $Id: syndication.php,v 1.3 2007-01-23 14:17:19 alexandre_tb Exp $
/**
* papyrus_bp - syndication.php
*
33,7 → 33,7
//Autres auteurs :
*@author Aucun
*@copyright Tela-Botanica 1999-2006
*@version $Revision: 1.2 $ $Date: 2006-12-13 17:20:51 $
*@version $Revision: 1.3 $ $Date: 2007-01-23 14:17:19 $
// +------------------------------------------------------------------------------------------------------+
*/
 
161,6 → 161,12
if (!isset($item['pubdate'])) {
$item['pubdate'] = date('dmY');
}
// Le code ci-apres est pour rattraper les dates du type 01012005 parsees par magpie
// lorsque les flux donne des dates au format iso
if (preg_match('/^([0-3][0-9])([0-1][0-9])([0-9][0-9][0-9][0-9])$/', $item['pubdate'], $match)) {
$item['pubdate'] = $match[3].'-'.$match[2].'-'.$match[1];
//echo $item['pubdate'];
}
$res .= str_replace ('{num}', ++$i,
str_replace ('{item}', '<a href="'.$item['link'].'" target="_top">'.$item['title'].'</a>',
str_replace ('{date}', strftime('%d.%m.%Y',strtotime($item['pubdate'])),
259,6 → 265,9
/* +--Fin du code ----------------------------------------------------------------------------------------+
*
* $Log: not supported by cvs2svn $
* Revision 1.2 2006/12/13 17:20:51 jp_milcent
* Correction bogue : paramètre nb non pris en compte
*
* Revision 1.1 2006/12/13 17:06:36 jp_milcent
* Ajout de l'applette Syndication.
*