For who it may help...
You can calculate age using the code below. This code accounts for the UNIX Epoch and leap years. All you need to do is provide it a date in the m/d/yyyy format.
<?php
$birthday = "7/4/1960"; //must be as m/d/yyyy
$bday = explode("/", $birthday); //parse
$b_mm = $bday[0]; //birthday month
$b_dd = $bday[1]; //birthday day
$b_yyyy = $bday[2]; //birthday year
//compare timestamps of mm/dd for birthday and today
$bday_mm_dd = mktime(0,0,0,$b_mm,$b_dd,0);
$today_mm_dd = mktime(0,0,0,date("m"),date("d"),0);
$age = date("Y", time()) - $b_yyyy;
if ($bday_mm_dd > $today_mm_dd) {
//birthday hasn't happened yet this year
$age = $age - 1;
}
print $age; //age equals 41 (in this case)
?>
Of course this code assumes the client and server machines exist in the same day.