Menu

#2 Albums dateorder instead of alphabetical

open
nobody
None
2
2001-07-30
2001-07-30
No

Hello,

PHPix 2.0 is excellent. Nowdays I've got more than 2500
pictures in it. To keep pictures order its neccessary
to make albums. But when I have many albums it's hard
to remember which is newest. For that I've been naming
albums with date date number. If i upload pictures
today, I'll name album to "30.7.2001". PHPix sort
albums by name. That causes albums to go "wrong" order,
like:

1.9.2000
25.7.2001
30.7.2001
3.1.2001

It would be good to have possibilty to order albums by
directory date. It's quite easily done with a little
modification in common.inc (2.0 stable)

[gabo@haisee valokuvat.haisee.com]# diff common.inc
common-dateorder.inc
103c103
<
---
> $directories=array();
108c108
< $dirlist[] = $file;
---
>
$directories[$file]=filemtime($realpixbase.$album."/".$file);
116a117,121
> arsort($directories);
> for($t=0;$t<sizeOf($directories);$t++) {
> $thisDir = each($directories);
> $dirlist[]=$thisDir[0];
> }
134c139
< if (is_array($dirlist)) { sort($dirlist); }
---
> // if (is_array($dirlist)) { sort($dirlist); }

Discussion

  • Anonymous

    Anonymous - 2001-07-30
    • priority: 5 --> 2
     
  • Nobody/Anonymous

    Logged In: NO

    I too would like to see this great php album sort in reverse
    chronological order.

    However, a quick solution to your problem would be to name
    your folders like so: 2001-12-31 then they would be in
    chronological order from oldest to newest.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.