• Resolved chreo

    (@chreo)


    Hi,
    You already answered in different topic that you can’t sort order of photos in album.
    But what about order of albums?

    On google photos albums are sorted (I think) by last updated photo (descending).
    Meanwhile in Photonic albums are sorted in some random way.

    I tried to specify album IDs to force order:
    [gallery type='picasa' user_id='xxx' kind='album' access='public,protected' protection='none' layout='square' caption='title-desc' thumb_size='160' main_size='200' filter='5960359653755748033,5536890446665533729,6025065661645867745,6375483016158301809']

    …but still albums were sorted in different order.

    Any idea how can I force order on plugin side?
    Or can you indicate in plugin code where request to google is executed?
    Maybe there is some option to use “order by”…
    …I think some old dead plugins had such option.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Sayontan Sinha

    (@sayontan)

    The answer is the same for albums – Picasa doesn’t offer a way to sort (see here: https://developers.google.com/picasa-web/docs/3.0/reference). The plugin displays the data in the same order that Picasa has returned.

    Remember that Google Photos displaying something in a particular order is different from Google’s API returning the data in a particular order. You can experiment by trying this link: https://picasaweb.google.com/data/feed/api/user/your-user-name?prettyprint=true, replacing your-user-name with the appropriate value. When I check this with my user name, I see this sequence:

    1. An album created in June 2016 and modified in Jan 2017
    2. An album created in Jan 2017 and modified in Jan 2017
    3. An album created in Nov 2016 and modified in Apr 2017
    4. Some older albums
    5. An album created in Sep 2006 and modified in Apr 2017
    6. Other older albums

    In all likelihood Google doesn’t use its APIs internally – the APIs are very restrictive and don’t allow for a lot of functionality that you see on the front end.

    I don’t believe the older Picasa API had any such option either; Photonic has supported sorting wherever available, and even before Google changed the Picasa API in mid-2016, I don’t recall ever having sorting in Photonic for Picasa.

    Plugin Author Sayontan Sinha

    (@sayontan)

    I retract this:

    I don’t believe the older Picasa API had any such option either; Photonic has supported sorting wherever available, and even before Google changed the Picasa API in mid-2016, I don’t recall ever having sorting in Photonic for Picasa.

    Photonic did support sorting prior to mid-2016 for Picasa, but since there is no capability in the API currently, it cannot be included with the plugin.

    Thread Starter chreo

    (@chreo)

    Wow, man! You’re fast! ??
    Thank you for answer.

    So now I am thinking about placing multiple single-album tags in my desired order:
    [gallery type='picasa' user_id='username kind='album' filter='111111']
    [gallery type='picasa' user_id='username kind='album' filter='222222']
    [gallery type='picasa' user_id='username kind='album' filter='333333']
    [gallery type='picasa' user_id='username kind='album' filter='444444']

    …but they are placed one UNDER another while I need them 4 in row.
    It is impossible I guess…so I need use Google API order ??

    In ‘Shahin plugin’ I could place albums in order (but plugin first stored info about each album in wordpress and then sorted albums:
    [shashin type=”album” id=”2,3,4,5,11,12,15,17,18,20,21,23,24,26,72,29,34,35,37,44,47,50,51,54,55,57,58,8,36,13″ size=”160″ crop=”y” columns=”4″ reverse=”y”]

    • This reply was modified 7 years ago by chreo.
    Plugin Author Sayontan Sinha

    (@sayontan)

    Well, when a plugin downloads data and stores it locally, it is essentially defining its own albums, at which point sorting is in its own control :). Photonic is, by nature, suited for dynamic displays, i.e. if you are adding new albums or adding new photos to an album, Photonic will get it for you without you having to modify your posts.

    You could tinker with the CSS styles and get a simulation of a regular grid after using a sequence of shortcodes, but I am not sure if it is worth the effort. If you still want to give it a shot, provide me with a URL that has the shortcodes invoked one after the other, and I will take a look.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Google photos albums sorting’ is closed to new replies.