Hi there - I may be over-complicating things but I am having a problem...

ok-

1st step - I can get the "current time" -


$tr=time();
echo "TIME = $tr<BR>\n";
RESULT "TIME = 1135860780"


OK...

I CAN get the last time a file was last modified :-

echo "FILe - '$file'<BR>\n";
if (file_exists($file)) {
$ta=date ("F d Y H:i:s.", filemtime($file));
   echo "The file was last modified: $ta<BR>\n";
}

RESULT = "The file was last modified: July 30 2005 03:05:20."


However - My  problem....

i am having a problem - Converting the time shown above - into a UNIX
timestamp...

$taw = date('d/m/Y H:i:s', $ta) ;
  echo "Time Modified = '$taw'<BR>\n";
$taw=strtotime('$ta');
   echo "Time Modified = '$taw'<BR>\n";
$taw=strtotime($ta);
   echo "Time Modified = '$taw'<BR>\n";



But the result I get is :-

Time Modified = '31/12/1969 16:00:00'
Time Modified = '-1'
Time Modified = '-1'

However - Im trying to get the ten-digit timestamp - based on the text
of the time....

Am I missing anything ? - I've been trying for 20-30 minutes with no luck....

--
G
Yahoo Archives by email = Yes
http://groups.kwister.com/owners.php#add
NZ community groups - [EMAIL PROTECTED]


------------------------ Yahoo! Groups Sponsor --------------------~--> 
Most low income homes are not online. Make a difference this holiday season!
http://us.click.yahoo.com/5UeCyC/BWHMAA/TtwFAA/HKFolB/TM
--------------------------------------------------------------------~-> 

Community email addresses:
  Post message: [email protected]
  Subscribe:    [EMAIL PROTECTED]
  Unsubscribe:  [EMAIL PROTECTED]
  List owner:   [EMAIL PROTECTED]

Shortcut URL to this page:
  http://groups.yahoo.com/group/php-list 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-list/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to