forum.coppermine-gallery.net
Support => cpg1.5.x Support => cpg1.5 miscellaneous => Topic started by: JohannM on March 05, 2015, 06:51:20 pm
-
Hi there
I am not sure where to post this ...
I want to sort my "Categories" according to the sql "cid" on my index page ... showing the latest category on top side and the oldest at bottom.
I tried everything in the code of the index.php page, but could not manage to get it working.
Help anyone ?
Please ... and thank you
-
Not 100% sure what you are asking for. A link and a little more details may help.
There are a few hidden sort features in Coppermine. The following plugin will allow you to configure them - http://forum.coppermine-gallery.net/index.php/topic,77314.0.html
-
Hi Phill
http://www.boy-idols.com/
Jaco Hoffmann ( http://www.boy-idols.com/index.php?cat=2 ) should be last on the page, and Milano Jarmann ( http://www.boy-idols.com/index.php?cat=50 ) should be first on the page.
I tried the Hidden features plugin for cpg1.5.x but it did not help me at all.
Rgerads
Jo
-
The easiest (and, currently, perhaps only) way for you to accomplish what you want is to make a small modification to the index.php file at the root of your gallery. The downside is that the change wouldn't survive an upgrade.
change the code at around line 362 from: ORDER BY NULL";
to: ORDER BY c.cid DESC";
-
Hi. Did the code change, but with no effect ... :-\
-
Hi. Did the code change, but with no effect
Sorry, I should have tested what I suggested :-[
Try, at about line 301, change:
ORDER BY lft";
to:
ORDER BY cid DESC, lft";
I'm pretty sure that should do it.
-
Perfect. Works like a bomb. Thanx a lot !!!!! :D