Return to Snippet

Revision: 44947
at June 22, 2011 00:30 by jrobinsonc


Updated Code
$birth_date = strtotime("1985-06-12");

printf("Tengo %d años de edad.", round(abs(time() - $birth_date)/60/60/24/365));

Revision: 44946
at June 22, 2011 00:27 by jrobinsonc


Updated Code
$today = strtotime("2011-02-03 00:00:00");
$birth_date = strtotime("1980-09-15 00:00:00");
printf("I'm %d years old.", round(abs($today-$birth_date)/60/60/24/365));

Revision: 44945
at April 21, 2011 04:42 by jrobinsonc


Initial Code
$today = strtotime("2011-02-03 00:00:00");
$myBirthDate = strtotime("1980-09-15 00:00:00");
printf("I'm %d years old.", round(abs($today-$myBirthDate)/60/60/24/365));

Initial URL

                                

Initial Description

                                

Initial Title
Script para calcular la edad

Initial Tags

                                

Initial Language
PHP