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: changing the order of pics when editing them  (Read 2733 times)

0 Members and 1 Guest are viewing this topic.

suprsonika

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
changing the order of pics when editing them
« on: March 31, 2005, 05:32:47 am »

I'm trying to order the photos by date when editing them. I found this in the FAQs:

By default, the pics are shown alphabetically when you edit them. To change the sorting order to "by date", edit editpics.php and change
$result = db_query("SELECT * FROM {$CONFIG['TABLE_PICTURES']} WHERE aid = '$album_id' ORDER BY filename LIMIT $start, $count");
to
$result = db_query("SELECT * FROM {$CONFIG['TABLE_PICTURES']} WHERE aid = '$album_id' ORDER BY pid LIMIT $start, $count");


That works, but it puts the older ones first, and I want the newest ones to be listed first. Anyone know how to change it?

Sarah

« Last Edit: April 01, 2005, 10:05:52 am by TranzNDance »
Logged

Nibbler

  • Guest
Re: changing the order of pics when editing them
« Reply #1 on: March 31, 2005, 10:14:56 am »

make it ORDER BY pid DESC
Logged

suprsonika

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
Re: changing the order of pics when editing them
« Reply #2 on: April 01, 2005, 09:49:09 am »

Thanks, it worked. You rock!

Sarah
Logged
Pages: [1]   Go Up
 

Page created in 0.019 seconds with 19 queries.