0

I am using the date function to get formatted time for timestamps between 0 and 86400. Therefore I expect to get 12:00am for timestamp 0, but instead I get 1:00am. Can anyone tell me why this is happening?

1
  • 2
    post your code please Commented Jan 1, 2014 at 20:22

2 Answers 2

1

It's because of your timezone setting, use gmdate instead

Sign up to request clarification or add additional context in comments.

Comments

1

Try changing the timezone your PHP date() function uses. It's probably +1:00 now.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.