Cannot sort any album by title/data/position Cannot sort any album by title/data/position
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Cannot sort any album by title/data/position

Started by flapane, March 18, 2012, 07:34:45 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

flapane

Latest CPG here.
The sort worked great until some time ago.
If you try to open any album and try to change the default sort order (ie. ascending date), you'll get a message stating that the selected file/album doesn't exist.
No matter what sort method I choose in the admin panel, it always sorts the thumbnails by name, while I prefer ascending data.
I disabled the Search Engine Friendly URLs plugin and deleted the htaccess file in order to see if it was the culprit, but it wasn't...
Any hints?
Thanks
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

flapane

errata corrige: I see that error message, but if I reload the album page the sort is correctly changed. I don't know which non-existent file/album CPG is referring to.
I've checked for error.log files in my webserver and found nothing.
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com

ΑndrĂ©

There's probably something wrong with your theme, as it doesn't replace any of the placeholder tokens:
Quote{TITLE}     +      -           {NAME}     +      -           {DATE}     +      -           {POSITION}     +      -

This results in links like
Quotehttp://www.flapane.com/gallery/thumbnails.php?album={AID}&page={PAGE}&sort=da


Check your theme or attach it as zip file to your next reply.

flapane

Gotcha!
The sort section of my theme.php was using the older sort method. Too bad I created my theme starting from my old original cpg 1.4 theme.

I changed
  <td width="100%" class="statlink">{ALBUM_NAME}</td>
                                <td class="sortorder_options" style="font-size: 100%;">{TITLE}</td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=ta" title="{SORT_TA}">&nbsp;+&nbsp;</a></span></td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=td" title="{SORT_TD}">&nbsp;-&nbsp;</a></span></td>
                                <td>&nbsp;&nbsp;</td>
                                <td class="sortorder_options" style="font-size: 100%;">{NAME}</td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=na" title="{SORT_NA}">&nbsp;+&nbsp;</a></span></td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=nd" title="{SORT_ND}">&nbsp;-&nbsp;</a></span></td>
                                <td>&nbsp;&nbsp;</td>
                                <td class="sortorder_options" style="font-size: 100%;">{DATE}</td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=da" title="{SORT_DA}">&nbsp;+&nbsp;</a></span></td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=dd" title="{SORT_DD}">&nbsp;-&nbsp;</a></span></td>
                                <td>&nbsp;&nbsp;</td>
                                <td class="sortorder_options" style="font-size: 100%;">{POSITION}</td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=pa" title="{SORT_PA}">&nbsp;+&nbsp;</a></span></td>
                                <td class="sortorder_options" style="font-size: 100%;"><span class="statlink"><a href="../../../gallery/thumbnails.php?album={AID}&amp;page={PAGE}&amp;sort=pd" title="{SORT_PD}">&nbsp;-&nbsp;</a></span></td>


with this
                                 <td style="text-align:right;" class="sortorder_cell" id="sortorder_cell">
                    <!-- Use JavaScript to display the sorting options only to humans, but hide them from search engines to avoid double-content indexing (js/thumbnails.js) -->
                </td>


Thanks
Flapane
www.flapane.com

Gallery
www.gallery.flapane.com