Announcement

#1 2024-03-18 15:31:09

Crythes
Member
2020-01-23
112

Can we sort albums case insensitive?

Hello/Hi/Greetings,

The issue is that if I have the following albums:

"Cat", "Apricot", "Man", MPO", "Mink".

The A-Z or the 1-5-10 album sort options will sort it the following way:

  [0]=>
  string(7) "Apricot"
  [1]=>
  string(3) "Cat"
  [2]=>
  string(3) "MPO"
  [3]=>
  string(3) "Man"
  [4]=>
  string(4) "Mink"

"MPO" should be the last item.

I think it's because it is using the PHP function sort which is by default case sensitive.

It should be replaced with either natcasesort() or usort().

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact