Skip to content

Instantly share code, notes, and snippets.

@sdeluce
Last active August 29, 2015 13:56
Show Gist options
  • Select an option

  • Save sdeluce/8952065 to your computer and use it in GitHub Desktop.

Select an option

Save sdeluce/8952065 to your computer and use it in GitHub Desktop.
Afficher le jour de la semaine et le mois en français dans une date.
<?php
$mois = array('00' => "",'01' => "Janvier",'02' => "Février",'03' => "Mars",'04' => "Avril",'05' => "Mai",'06' => "Juin",'07' => "Juillet",'08' => "Août",'09' => "Septembre",'10' => "Octobre",'11' => "Novembre",'12' => "Décembre");
$jours = array("","Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi", "Dimanche");
$jour = $jours[date("N", strtotime($result->date))];
$mois = $moiss[date("m", strtotime($result->date))];
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment