win32 filetime conversion

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jane

    win32 filetime conversion

    Hi,

    I need a function to convert a date/time (dd-mm-yyyy hh:mm:ss) to a 64-bit
    win32 FILETIME and reversed.
    Is this possible with PHP ?

    Thansk in advance,

    Jane


  • SquishedOrange

    #2
    Re: win32 filetime conversion

    Yeah,
    But the only way I can think of doing it is messy.

    Use strtotime() to get the Linux timestamp for a date (seconds since
    January 1 1970 00:00:00 GMT), then add quite large interger to get it
    to the number of seconds since January 1, 1601. Then you need to
    multiply this by some factor of 10 to get into 100-nanosecond
    intervals.

    Sorry, Can't be bothered to do it for you ;)

    Btw, strptime() is nicer, but is only php5+

    Not sure what your doing with the reverse bit though..

    Comment

    • Jane

      #3
      Re: win32 filetime conversion

      I'll give it a try.
      The reverse part is from a 64-bit value to a date/time.

      Maybe i need to use some Perl code within my php.

      Jane


      Comment

      Working...