Subversion Repositories Applications.projet

Compare Revisions

Ignore whitespace Rev 404 → Rev 405

/trunk/classes/ezmlm-php-2.0/ezmlm.php
1,5 → 1,5
<?php
// $Id: ezmlm.php,v 1.9 2008-11-19 09:28:46 aperonnet Exp $
// $Id: ezmlm.php,v 1.3.2.2 2007/03/13 11:04:46 alexandre_tb Exp $
//
// ezmlm.php - ezmlm-php v2.0
// --------------------------------------------------------------
30,7 → 30,7
require_once("ezmlm-repondre.php");
require_once("ezmlm-author.php");
 
$GLOBALS['mois'] = array ('Jan', 'Fév', 'Mars', 'Avril', 'Mai', 'Juin', 'Juil', 'Août', 'Sept', 'Oct', 'Nov', 'Dèc') ;
$GLOBALS['mois'] = array ('Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre') ;
 
// CLASS: ezmlm_php
// the base class, contains common functions and the config
118,6 → 118,16
/*$this->error(EZMLM_INVALID_DIR,TRUE);*/
}
}
/*
* Renvoi le nombre de message dans une archive
* Le nombre contenu dans liste/num
*/
function getNumArchive() {
if ($this->listdir != '') {
$num = split(':', file_get_contents($this->listdir.'/num'));
return $num[0];
}
}
 
function set_action($action) {
if (is_array($action)) { $this->error(EZMLM_INVALID_SYNTAX,TRUE); }
233,7 → 243,7
$outstr = preg_replace("/&lt;.*&gt;/", '', $outstr);
$outstr = preg_replace("/[\"']/", '', $outstr);
}
 
$at_split = explode('@',$outstr);
$outstr = $at_split[0];
 
263,7 → 273,7
if ($critical) { die; }
}
/**
* Parse une chaime et supprime les problème d'encodage de type ISO-4 ...
* Parse une chaine et supprime les probleme d'encodage de type ISO-4 ...
*
* @return string
*/
301,10 → 311,10
*/
function date_francaise ($date_mail) {
$date_mail = preg_replace ('/\(?CEST\)?/', '', $date_mail) ;
$date_mail = preg_replace ('/CEST/', '', $date_mail) ;
$numero_mois = date('m ', strtotime($date_mail)) - 1 ;
$date = date ('d ', strtotime($date_mail)).$GLOBALS['mois'][$numero_mois] ; // Le jour et le mois
$date .= date(' Y ', strtotime($date_mail)) ; // l'année
$date .= date(' Y ', strtotime($date_mail)) ; // l'annee
if (date('a', strtotime($date_mail)) == 'pm') {
$date .= (int) date('g', strtotime($date_mail)) + 12 ; // Les heures
} else {