Convert timestamp into year, month, days, hours, minutes, seconds in PHP
I need to convert datetime into year, month, days, hours, minutes,
seconds; my date is saved in database like this: 2011-11-30 05:25:50.
Now I want to show like year, month, days, hours, minutes and seconds in
PHP like: 2 year,5 month 10 days, 10 hours, 45 minutes, 30 seconds.
I have searched about this but not understand how I can do this,I know
there are many questions at this topic on Stack Overflow, maybe it is
duplicate but I am unable to solve my issue.
Thanks in advance.
No comments:
Post a Comment