• Resolved sway25

    (@sway25)


    Hi,

    I’m fairly new to this.

    I keep getting the error code: No data returned: Error code 401 when I’m in the “Edit Photonic Gallery (Source: Smugmug)” window where I get to choose what type of gallery I want to use and for whom. I actually went through the entire process the first time and the gallery worked perfect. I went back in to change the type of gallery from Albums to User Tree and that’s when I began getting the error code. API, user id, and authentication is good to go. Using Deluxe GoDaddy hosting.

    This is the shortcode that comes up:
    <!– wp:photonic/gallery {“shortcode”:”{\u0022type\u0022:\u0022smugmug\u0022,\u0022view\u0022:\u0022albums\u0022,\u0022album_sort_order\u0022:\u0022Last Updated (Descending)\u0022,\u0022columns\u0022:\u0022auto\u0022,\u0022title_position\u0022:\u0022slideup-stick\u0022,\u0022popup\u0022:\u0022hide\u0022,\u0022layout\u0022:\u0022masonry\u0022}”} /–>

    The page I need help with: [log in to see the link]

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

    (@sayontan)

    I am seeing your gallery fine … https://imgur.com/a/R5RPQSJ

    Plugin Author Sayontan Sinha

    (@sayontan)

    BTW, the code you have pasted out above refers to the “albums” view, not the “user tree” view. Are you having trouble generating the block for “user tree”? Is that where you are encountering the failure?

    Thread Starter sway25

    (@sway25)

    Hi, yes that is correct. I left it alone for now while it’s working. I want to use the user tree block.

    Thread Starter sway25

    (@sway25)

    Once I change the option to “User Tree” and select “Current User” and hit Next, that’s where the error comes up and it won’t let me continue any further.

    Plugin Author Sayontan Sinha

    (@sayontan)

    OK.

    A few things:

    1. Instead of modifying the existing block, can you try creating a new one for the user tree with the same options? If it works you can delete the older one.
    2. Do you require authentication? Authentication is required if you have private photos, but when I pass your SmugMug nickname to the UI at my end, I am able to see all your albums, or even your user tree (with 10 folders). So I am guessing your content is not private? If that is the case, try deleting the “access token” from Photonic → Settings → SmugMug → Access Token (for Back-end / Server-side Authentication). A 401 error points to invalid security credentials, so there may be something wrong with the token.
    Thread Starter sway25

    (@sway25)

    Deleted the “access token” and it allowed me to make the required changes. Once I tried to preview it, I got this message:
    There was an error connecting to smug. Please try again later.
    1 Message:
    cURL error 28: Operation timed out after 50000 milliseconds with 0 bytes received

    I’m running WordPress 5.0.3 and PHP version 7.2

    Plugin Author Sayontan Sinha

    (@sayontan)

    In most cases this is not a plugin bug and it may be caused because of two reasons:

    1. Intermittent connectivity issues between your site and SmugMug. Generally retrying after a while fixes the issue automatically.
    2. If you are repeatedly facing the issue, you can bump up the cURL timeout (Photonic → Settings → Advanced → Increase cURL timeout), but you have to ask first yourself if you should try to display a user tree in such a case, because increasing the cURL timeout would also impact the load speed of your page. SmugMug’s API is pretty streamlined, so in most cases you might be fine, but if your folder structure is quite crazy, you might want to go back to showing all albums.
    Thread Starter sway25

    (@sway25)

    I currently have the timeout set to 50 (obviously not helping).

    There are actually 27 folders with multiple albums in each one. I think it’s too much. I might have to keep it the way I had it before. Is there a way to be able to show the folder name, album name, and quantity of pics on the album title display overlay on the thumbs?

    Plugin Author Sayontan Sinha

    (@sayontan)

    There are actually 27 folders with multiple albums in each one. I think it’s too much.

    Yes, that might cause a fair bit of churn on SmugMug’s side. Retrieving a flat list of albums is a lot simpler from SmugMug’s point of view.

    Is there a way to be able to show the folder name, album name, and quantity of pics on the album title display overlay on the thumbs?

    When I was designing the interface I had made a conscious decision to leave this out of the block/shortcode builder, so there is no way to show this. The reasoning was that the block/shortcode builder is mostly a one-time thing, and though important, it is used a lot less than the front-end of your website. Consequently if you had long album / folder / photo titles, those would start messing with the layout, and probably cause more confusion – something that I didn’t (and still don’t) have the bandwidth to support.

    I did add a search feature to narrow your results though, but I don’t think you are looking to use it.

    Thread Starter sway25

    (@sway25)

    Thank you, I switched it back to albums. I’ll have to leave it as is. Is there any way to make the gallery descending order horizontal (left to right) instead of vertical?

    Plugin Author Sayontan Sinha

    (@sayontan)

    The masonry layout goes from top to bottom, so you cannot sort horizontally there.

    You might want to try the Justified Grid layout, which will help sort horizontally.

    Thread Starter sway25

    (@sway25)

    Thank you, Sayontan. This is an awesome plugin!

    Thread Starter sway25

    (@sway25)

    Hi Sayontan, I am now interested in your search feature. Please let me know what I need to do.

    Plugin Author Sayontan Sinha

    (@sayontan)

    Nothing— you will see an option to search by name when you are building the gallery.

    Thread Starter sway25

    (@sway25)

    Is there a search field option for front end users?

Viewing 15 replies - 1 through 15 (of 17 total)
  • The topic ‘No data returned’ is closed to new replies.