Skip to content

Instantly share code, notes, and snippets.

@kovek
Created April 5, 2013 16:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kovek/5320552 to your computer and use it in GitHub Desktop.
Save kovek/5320552 to your computer and use it in GitHub Desktop.
function date($string){
$dateArray = explode('-', $string);
$output = "";
$months = array(
1 => "January",
2 => "February",
3 => "etc, dont forget to continue the array"
)
$output += $months[$dateArray[1]] ." ";
$output += $dateArray[0] .", ";
$output += $dateArray[2];
return $output;
}
@kovek
Copy link
Author

kovek commented Apr 5, 2013

$string is the string outputed by the MySql Date query

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment