Re: Convert input to Unix Timestamp



eclipsme wrote:
Jerry Stuckle wrote:
eclipsme wrote:
What is the suggested best ways to accept a date in a form that will be input into a table as a timestamp? I only care about the year-month-day, not the time.

Thank you,
Harvey

Whatever format you is most convenient for the user. You can always massage the format internally before putting it in the database.

What commands are used to 'message the format'?

strtotime? date()?

Thanks,
Harvey

It entirely depends on the format you get your data in.

The problem is - you're asking the wrong question. The first question should be - "What is the most user-friendly way to get the date?". This answer can easily vary, depending on the rest of your page (and site).

Once you have that, your next question can then be "How do I convert this to a format which is acceptable by the database?".

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@xxxxxxxxxxxxx
==================
.



Relevant Pages

  • Re: Johanna Martzy Dvorak DGG 10" LPE 17178 on ebay
    ... high end audio shows, where equipment makers don't care about format. ... Tubes amplification,is in my book,as or more important than vinyl.Is ...
    (rec.music.classical.recordings)
  • Re: green / blue screen tips needed
    ... Knowing what format you're actually recording on is important. ... an ENG camera, but is that Beta SP that uses a 4:2:2 compression scheme, or ... or take extra care to light accordingly. ... > and studio with full crew. ...
    (rec.arts.movies.production)
  • Re: HD-DVD vs Blu-Ray - who cares?
    ... that the majority of people, including myself, are waiting for one format - ... VHS / Beta was the introduction of video tape - so people had to pick one ... Even though we all had VHS - the move to DVD was rather quick. ... I dont care, ...
    (alt.tv.tech.hdtv)
  • Re: Tricks to impress Windows users
    ... looks, appearance and format. ... just that I don't care David? ... lowest common denominator. ... A .pdf fixes the document layout and appears identical on any platform. ...
    (uk.comp.sys.mac)
  • Re: OT: Blog-City support even worse than Party Pokers
    ...    Do you think any of us care about your petty problem. ... They showed an example of the correct tags command format. ... So, it not being the tags command wrong, I switched to those category URLs ...
    (rec.gambling.poker)