Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Search results don't sort according to config pref  (Read 3265 times)

0 Members and 1 Guest are viewing this topic.

windfate

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
Search results don't sort according to config pref
« on: July 22, 2004, 11:13:59 pm »

Hi -

I'm enjoying 1.3.1.  Great work!  I have a question I've seen raised a few times but didn't notice any responses.

Clicking into an album will sort fine, but I've noticed that Search results still do not sort according to the preferred method selected in the Config (eg, "Title ascending", etc.).  Does anyone know where I would go in the code to hardcode a field to sort to when searching?  I've poked around a bit but don't see it.

Might this be implemented in a future release?

Thanks!

windfate
Logged

Nibbler

  • Guest
Re: Search results don't sort according to config pref
« Reply #1 on: July 22, 2004, 11:29:37 pm »

I've just added it into the next version (1.4), thanks for your suggestion :)

If you want to add it yourself, the file you need to look at is /include/search.inc.php
Logged

windfate

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
Re: Search results don't sort according to config pref
« Reply #2 on: July 23, 2004, 05:21:59 pm »

Thanks Nibbler.  I took a look at the file and I think I found where I need to insert something (around line 150?).  I thought I would try and see how sorting is being done in thumbnails.php but I didn't find "sort" anywhere in that file (must be in another include).  I found some uses of array_multisort() in some of the other files and gave that a whirl, but I quickly realized I'm missing some key concepts in sorting data from sql queries.

If it's a simple addition to the code, could you post it here?  Would be much appreciated!

Thanks for your help.

windfate
Logged

Nibbler

  • Guest
Re: Search results don't sort according to config pref
« Reply #3 on: July 23, 2004, 06:27:54 pm »

You can see the changes to the file by using the CVS diff, just here.
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 20 queries.