Time Stamps

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • The1corrupted
    New Member
    • Feb 2007
    • 134

    #1

    Time Stamps

    No matter what I do, I cannot wrap my head around time stamps... For instance..

    [PHP]
    $time=$_SERVER['request_time'];
    [/PHP]
    I think that's what it is... at any rate, how can I make a true time stamp with minutes and seconds?
  • xwero
    New Member
    • Feb 2007
    • 99

    #2
    Originally posted by The1corrupted
    No matter what I do, I cannot wrap my head around time stamps... For instance..

    [PHP]
    $time=$_SERVER['request_time'];
    [/PHP]
    I think that's what it is... at any rate, how can I make a true time stamp with minutes and seconds?
    you have to use the date function.

    [PHP]date('d-m-Y H:i:s',$time);[/PHP]

    Comment

    • The1corrupted
      New Member
      • Feb 2007
      • 134

      #3
      Could I chop that down some like this:

      [PHP]
      date('i:s', $time);
      [/PHP]

      Comment

      • xwero
        New Member
        • Feb 2007
        • 99

        #4
        Originally posted by The1corrupted
        Could I chop that down some like this:

        [PHP]
        date('i:s', $time);
        [/PHP]
        of course for more date function arguments check http://be2.php.net/manual/en/function.date.p hp

        Comment

        Working...