I want to get current time of US/Eastern timezone. How would I achieve that.
I have tried following code but it is displaying my system\'s time.
<
The easiest way is probably to use gmmktime() to get the Unix timestamp for the current GMT, then subtract 5 hours from it. That way you get Eastern Time no matter where the server happens to be.
gmmktime()
Unix timestamp
subtract 5 hours