View Full Version : Default Category Display Order
June 22nd, 2011, 04:50 PM
I have my categories set to display by 'display order' instead of alphabetically, and 'descending' instead of ascending.
The problem is that any time I edit one of the categories' name or description, the sort order is changed to 'ascending' - resulting in my category list being flipped upside down. The fix is to toggle from descending, to ascending, and back in the VBG admin settings.
I'm assuming the default in the code is 'ASC' - can anyone help me find where I might change that to 'DESC'?
July 6th, 2011, 05:55 PM
I found the code for this at line 74 in gallery/index.php - I tried hard-coding 'ORDER BY displayorder DESC' - but it's still doing the weird behavior I described above. Is anyone else seeing this?
July 6th, 2011, 06:20 PM
I take it your modifying code which is probally your issue. The category on index is set by ordering the categories specifically in edit categories in admin using the category order feature. The sort order of photos in a specific category is set default in edit categories for each category the set prelist of sorts you can set them to. You can override any default when viewing a cat of images but that is specifically for one viewing till you close your browser. That is how sorting works in the program.
July 7th, 2011, 11:03 AM
The only modification that might affect this area is that I'm using VBSEO seems strange, but if nobody else is experiencing the same, I trust that it is something on my end.
July 7th, 2011, 02:46 PM
You are setting a display order in edit categories in admin right ;)
If you do your categories list will display as you set it.
July 7th, 2011, 02:52 PM
I am numbering them in the display order fields - yes. the issue is that they switch to Ascending anytime I edit any of the categories. Even tho it is set to Descending in 'Modify Settings' - so I have to toggle to Ascending > save, then Descending > save in order to get it back to Descending..
July 7th, 2011, 02:58 PM
I tested and whatever order I set them to in edit categories and hit SAVE DISPLAY ORDER they are saved in that order and even if I edit a category the display stays the same for me so maybe some code alteration your doing is affecting things? You did say you have changed code.
July 7th, 2011, 03:00 PM
Ok good to know - must be something w/ VBSEO or modifications I've made to other areas - I'll investigate w/ that in mind. thanks for confirming!
July 7th, 2011, 07:27 PM
vBulletin® v3.8.1, Copyright ©2000-2014, Jelsoft Enterprises Ltd.