PHP function of the day: gettimeofday()

For day 4 of 21 in the “PHP Function of the day” series, I’m going to look at gettimeofday().  The function gets the current time of the day.

Let’s take a look.





See the output


Since gettimeofday() outputs an array, we are using print_r() instead of echo() but don’t focus on that, yet.  The array includes seconds since the Unix Epoch, microseconds, minutes west of Greenwich, and type of dst correction.

Leave a Reply

Your email address will not be published.