Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8623769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T07:21:46+00:00 2026-06-12T07:21:46+00:00

I have a unix timestamp (int) in PHP. I want to display this value

  • 0

I have a unix timestamp (int) in PHP. I want to display this value in a nice manner in the HTML5 datetime input element. I would like to be able to have users see this value in a nice presentable manner, as well as edit it. Is there any nice way of doing this, or am I fooling myself and I am going to have to fuss around with lots of string manipulation?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T07:21:47+00:00Added an answer on June 12, 2026 at 7:21 am

    HTML5 Input time is something like this : 1985-04-12T23:20:50.52

    You can do that in PHP like this :

    echo date("Y-m-d\TH:i:s");
    

    Output

    2012-10-02T19:12:49
    

    HTML with Timestamp

    <input type="datetime"  value="<?php echo date("Y-m-d\TH:i:s",$timestamp); ?>"/>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have this unix timestamp value: 1275364800 (1st june 2010). When printing that value
I have a unix timestamp like this one: 1323668326 . I want to convert
I want to display $eventdate (saved as a unix time INT value on SQL
Assuming I have a unix timestamp in PHP. How can I round my php
I have two unix timestamps as LONG INT. I want to subtract start from
I have a UNIX-type timestamp stored in an INT column in MySQL. What is
In my javascript, I have a unix timestamp (in this instance `1318305600000) and I
I'm using this to convert date time strings to a unix timestamp: str(int(time.mktime(time.strptime(date,%d %b
I have a Unix timestamp like this: $timestamp=1330581600 How do I get the beginning
I have a Unix timestamp that I need to get the individual year, month,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.