Hi Dave,

Tuesday, May 22, 2007, 5:46:38 PM, you wrote:

> How can I convert the numerical day of week to the string version?
> Example, if the day of the week is 1 I would like to print out 'Sunday'.

$days = array(1 => 'Sunday', 2 => 'Monday', 3 => 'Tuesday', etc ...);

then just

$today = $days[1]; // Sunday
$today = $days[3]; // Tuesday

Cheers,

Rich
-- 
Zend Certified Engineer
http://www.corephp.co.uk

"Never trust a computer you can't throw out of a window"

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to