sweet , damn filemtime this was hiding from me :)

-----Original Message-----
From: Bas Jobsen [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 14, 2002 8:48 PM
To: electroteque; [EMAIL PROTECTED]
Subject: Re: [PHP] fopen and sort by date modified

Op woensdag 14 augustus 2002 13:04, schreef electroteque:
> hi there i was wondering how i could fopen a directory and then sort the
> files by date modified is there a way ?

// Note that !== did not exist until 4.0.0-RC2
if ($handle = opendir($dir))
    echo "Directory handle: $handle\n";
    while (false !== ($file = readdir($handle)))
        echo $file;
echo $k.':'.date('r',$v)."\n";

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to