Subversion Repositories eFlore/Applications.del

Rev

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

Rev 216 Rev 540
Line 387... Line 387...
387
       $date = explode('-', $val[0]);
387
       $date = explode('-', $val[0]);
388
       $heure = explode(':', $val[1]);
388
       $heure = explode(':', $val[1]);
389
       return mktime((int) $heure[0], (int) $heure[1], (int) $heure[2], (int) $date[1], (int) $date[2], (int) $date[0]);
389
       return mktime((int) $heure[0], (int) $heure[1], (int) $heure[2], (int) $date[1], (int) $date[2], (int) $date[0]);
390
	}
390
	}
Line -... Line 391...
-
 
391
	
-
 
392
	protected function formaterChaineMinusculeSansAccents($chaine) {
-
 
393
		$chaine = $this->supprimerAccents($chaine);
-
 
394
		$chaine = str_replace(' ','_',$chaine);
-
 
395
		$chaine = str_replace('-','_',$chaine);
-
 
396
		
-
 
397
		return mb_strtolower($chaine);
-
 
398
	}
-
 
399
	
-
 
400
	protected function supprimerAccents($str, $charset='utf-8') {
-
 
401
		$str = htmlentities($str, ENT_NOQUOTES, $charset);
-
 
402
		
-
 
403
		$str = preg_replace('#&([A-za-z])(?:acute|cedil|circ|grave|orn|ring|slash|th|tilde|uml);#', '\1', $str);
-
 
404
		$str = preg_replace('#&([A-za-z]{2})(?:lig);#', '\1', $str); // pour les ligatures e.g. 'œ'
-
 
405
		$str = preg_replace('#&[^;]+;#', '', $str); // supprime les autres caractères
-
 
406
		
-
 
407
		return $str;
-
 
408
	}
391
	
409
	
392
	protected function etreNull($valeur) {
410
	protected function etreNull($valeur) {
393
		$etre_null = false;
411
		$etre_null = false;
394
		if ($valeur == '' || $valeur == null || $valeur == '000null' || $valeur == 'null' || $valeur == '*') {
412
		if ($valeur == '' || $valeur == null || $valeur == '000null' || $valeur == 'null' || $valeur == '*') {
395
			$etre_null = true;
413
			$etre_null = true;