• Resolved wpngguser

    (@wpngguser)


    Hi,

    I’ve asked previously about this in another thread and was requested to start my own topic.

    At the moment, all galleries are always sorted with the oldest starting first. Could an option be provided to always pull the gallery list with the newest galleries first? I’ve been using NextGen Gallery for roughly a year and am approaching 100 galleries, so it’s inconvenient at best to have them always sorted with the oldest one first.

    Specifically, the Manage Galleries page and the gallery select list when I go to insert a gallery into a post would be nice to have the newest first. But I don’t imagine there are any instances where I would want the oldest at the top of the list.

    Thanks!

Viewing 9 replies - 1 through 9 (of 9 total)
  • This has bugged me for years and would take minutes on the part of the authors to resolve. There should be an option at the very least, under ‘Screen Options’ to do that.

    And it should include an option to view the images in the gallery newest first as well, as one may be adding to an already large gallery.

    Failing anything else please give us some code to put in functions.php to resolve it.

    Add this to your theme’s functions.php

    // change default order in ngg to newest first
    add_filter('ngg_manage_galleries_items_orderby', 'set_ngg_orderby');
    	add_filter('ngg_manage_galleries_items_order', 'set_ngg_order');
    	function set_ngg_order($order) {
    	    return 'DESC';
    		}
    	function set_ngg_orderby($orderby) {
    		return 'gid';
    		}

    It will change the order to newest first. BUT it won’t change the order of photos within a gallery. Nor will it change the order in the drop down list in “Import from WordPress Media Library”

    If anyone knows how to do that, or knows what the hooks are, please tell.

    • This reply was modified 7 years, 5 months ago by digbymaass.
    Thread Starter wpngguser

    (@wpngguser)

    Thanks for that, it does indeed fix the sorting on the “Manage Galleries” page. I’d managed this before, but the changes I made were in the gallery code and always got overwritten each time it updated. This should persist now given the changes are in the theme files.

    Hopefully the authors can take a moment to add some global sorting options that will solve this issue once and for all. I still have a long way to scroll in the select lists…

    Cheers!

    Plugin Contributor Imagely

    (@imagely)

    @wpngguser & @digbymaass – You are welcome to submit PR’s at https://bitbucket.org/photocrati/nextgen-gallery/pull-requests/ … or, you can also send in Feature Requests here: https://imagely.com/feature-voting/

    Thanks, again!

    – Cais.

    I’ve done that in the past.

    The people with few and small galleries obviously far outweigh those with many and large ones.

    Is there a way of automatically showing images newest first in galleries when managing a gallery, using something in functions.php?

    • This reply was modified 7 years, 5 months ago by digbymaass.
    Plugin Contributor Imagely

    (@imagely)

    @digbymaass – Let’s have a separate conversation in a new topic or feel free to use our contact form. Interrupting other topics will not help congeal your ideas or provide them with any additional momentum.

    If you have submitted a PR then that is the best approach currently; if you are looking for something different, please start your own topic so we can try to help you with your specific issue on your specific site.

    See https://make.www.ads-software.com/support/handbook/forum-welcome/#post-in-the-best-place

    Thanks!

    – Cais.

    It was absolutely relevant to the topic. I have EXACTLY the same issue as the OP. Please deal with the issue.

    Thread Starter wpngguser

    (@wpngguser)

    In addition to that, I posted about this previously in another thread and was told to create my own topic so I did. Now I need to submit pull or feature request?

    Is this request just not possible? I’m fine with that, I’m just not sure why there’s the run-around.

    Plugin Contributor Imagely

    (@imagely)

    @wpngguser – Doing all of the refactoring that may be required to change the interface is possible, although a forum topic here does not carry as much influence as a PR or Feature Request could. Either of those venues will go into our support platform; and, are part of our release planning references.

    We do hear these requests and although we also see their potential benefits we weigh all feature request ideas against all other contributing factors such as existing issues, planned enhancements, and significant new feature sets when scheduling our developers’ time.

    Thanks!

    – Cais.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Sorting galleries by newest first’ is closed to new replies.