1

I am trying to convert a unix timestamp into readable text. The timestamp is stored in a database and shown in a table. The problem is the results are not accurate.


Code:

<td>'.date("F j, Y, g:i a", strtotime($row['expire'])).'</td>


database:

enter image description here


Result:

enter image description here

1
  • @Evan Mulawski i update my question to show expire Commented Jun 16, 2012 at 0:12

1 Answer 1

3

Two options:

  • Remove the strtotime call, since you already have the timestamp as a number, OR
  • Change the database field to TIMESTAMP.
Sign up to request clarification or add additional context in comments.

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.