View Single Post
  #8  
Old 10-26-2013, 08:21 AM
merc07 is offline merc07
Registered User

Join Date: Oct 2013
Posts: 2

Sorted it using rsort..

//Lets get some images!!
$dir = $full_server.$album.'*';
//Loop through them all .
$all_files = (glob($dir));
rsort($all_files);
foreach($all_files as $file){

Thanks
Adam


Quote:
Originally Posted by Scott View Post
To be honest, there is no exact order. To put the files in order you will have to change the code.... look for this bit of code (Starts near line 514):

PHP Code:
//Lets get some images!!

$dir=@opendir($full_server.$album);

//Loop through them all ;).

while($file=@readdir($dir)) { 
and replace it with this:

PHP Code:
//Lets get some images!!
$dir $full_server.$album.'*';

//Loop through them all ;).

foreach(glob($dir) as $file){
    
$file substr($filestrlen($dir)-1); 
That should order them alphabetically.
Reply With Quote