• Resolved davidlag

    (@davidlag)


    Hello!

    I’m helping an animal shelter with their web site that was built using WordPress. We currently have a gallery that shows pictures here: https://refugealsa.com/lapins-presentement-a-ladoption/

    We would like to enhance what we currently have to add the following:
    – Keep the same photo grid (at the link above) to show only cover album photos.
    – When we would click on an album cover photo in the grid, open a lightbox to show the other photos part of the album.
    – In the lightbox, show the album description that will provide more information on the animal.

    I have played with the photo album plugin for a few hours and the closer I could get is here: https://refugealsa.com/test-de-galerie/

    I couldn’t find a way to have the photos appear as a grid without the gray boxes around them. I also couldn’t find how to show the album description in the lightbox.

    I couldn’t find if what I’m after is possible or not without custom CSS and/or JavaScript. Any pointer would help a lot!

    Thank you very much! This is really the best photo album plugin I could find so far!

    David

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

Viewing 15 replies - 16 through 30 (of 36 total)
  • Thread Starter davidlag

    (@davidlag)

    Thank you for your patience. I did some tests tonight and it works great! A few questions/comments:

    – When I set size="..." using a shortcode and set it to 960, I see 4 columns but when I resize the browser window then there is no responsiveness. Is this the intended behaviour?
    – With just [wppa align="center"][/wppa] it works great. The screen is quite filled on a widescreen but it doesn’t seem an issue right now.
    – The functionality you added for a w# code for showing the album description in a photo description works great. Super useful with our use case!
    – We had a last requirement I didn’t mention at first, my bad. Everything else seemed more important considering how hard it was to find just a grid showing album covers and a lightbox to look at the albums. Do you offer a way to resize the thumbnails the way we want? A bit like big techs (Facebook, Google Photos) offer a square you can move around over your profile picture to keep what you want and crop the rest. Sometimes, the animal isn’t centered in the photo and if we don’t fix the thumbnail, we would only see part of it.
    – A new feature we have that could be useful if you don’t offer it already: is it possible, when in a lightbox, to click on the photo to move to the next photo and so on without using the navigation buttons but get the same behaviour as the navigation buttons with a click on the photo?

    You can see the result so far here:
    https://refugealsa.com/test-de-galerie/

    Again, thank you so much for all your time and efforts to help us out. This is deeply appreciated!

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    – Yes this is the way to make a fixed column in a responsive environment.
    To make ‘responsive but max 960’ write: size="auto,960"

    – If you keep the full column (no size specified) even align="center" is redundant, just [wppa] is enough to get a generic display (the toplevel album covers full width).

    – w#albumdesc was the simplest addition

    – Manual cropping is not supported (yet)

    – Try Table IV-G2 set to ‘Browse (left/right)’and click on the background

    Thread Starter davidlag

    (@davidlag)

    Just took some other time to test after your reply:

    size="auto,960" does exactly what I was trying to do to limit the number of columns! Thanks!

    – Is there a way we could use another plugin specifically to manually crop thumbnails? Could that plugin easily have access to thumbnails and not break the rest of the setup and work well with your plugin?

    – I set Table IV-G2 to ‘Exit (close)’ already as I find it easier to leave the lightbox this way! We’ll think about it for what is best for us.

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    I will see if i can quickly implement clicking the image: right half -> next, left half -> previous.

    Read this: https://wppa.nl/docs-by-subject/imagemagick/
    Maybe in the near future i can implement it there

    Thread Starter davidlag

    (@davidlag)

    Ok, let me know for the image browsing! Otherwise, I’ll check the release notes! πŸ™‚

    We have imagemagick as far as I’m aware. It gives a lower health score if we do not have it as WordPress recommends it.

    I noticed that when I try to import photos from your plugin, I cannot do it from our other gallery. Is this a restriction that WordPress imposes for security reasons (a plugin cannot access another plugin’s data) ? If we find another plugin to crop images meanwhile, should it have access to the thumbnails in Photo Album Plus?

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    This zipfile: https://downloads.wordpress.org/plugin/wp-photo-album-plus.7.2.02.003.zip is the latest tagged version (release candidate). You can install it like you did with the dev version. Tick Table IV-G2.2: Click om image, to browse on image click.

    The way i use imagemagic (by escaped shellcommand) does not add anything to the vulnerability score as computed by Coderisk

    You can import any valid filetype (like .jpg) from anywhere inside wp-content using the Import Photos admin page, set to ‘Local’.
    If you switch to ‘Remote’, you can enter any url, to any page (that contains images) or even to images directly. See the description in the ‘Import photos from:’ input box.

    You should have access to all files inside the wppa content from other plugins.
    You can find the urls to the photofiles in the photo admin pages. e.g.:
    Permalink: https://betatest.opajaap.nl/wp-content/wppa-pl/opajaap/1200-675.jpg
    Hi resolution url: https://betatest.opajaap.nl/wp-content/uploads/wppa-source/album-74/1200-675.jpg
    Display file url: https://betatest.opajaap.nl/wp-content/uploads/wppa/1560.jpg
    Thumbnail file url: https://betatest.opajaap.nl/wp-content/uploads/wppa/thumbs/1560.jpg

    Thread Starter davidlag

    (@davidlag)

    Thank you Jacob!

    For some reason I missed your last comment on the thread here. I saw the plugin update and just tested the new version and enabled the option to browse images with a click on left/right half of the image and it works great! πŸ™‚

    I did some research the other day and found some JS projects to crop photos. I built a list of general ideas to get going:

    β€’ Check if WPPA+ plugin is loaded
    β€’ Yes:
    β—‹ Get list of all albums and show them with a drop-down menu. Only show the album names that have a specific cover photo set.
    β—‹ When an album is selected in the list, get name of original photo and show it in the cropping tool with the size of the cropping rectangle set to thumbnail size based on the database information for the photos. Also get the thumbnail ID.
    β—‹ Use this JS cropping tool:
    Β§ https://foliotek.github.io/Croppie/
    β—‹ Otherwise use this one:
    Β§ https://fengyuanchen.github.io/cropperjs/
    β—‹ Get new coordinates from the JS cropping tool and use that information to build the command to run imagemagick to update the thumbnail.
    β—‹ When user is done with cropping and click on the “Crop” button, update the thumbnail by overwriting it using imagemagick and provide a feedback to user.

    Another thing I know for sure I’m missing here is if there would be a general update of the thumbnails from WPPA+. I would need to trigger on that change and also keep a list of changes done with the cropping tool to re-apply them.

    I know this is really simple and bare bones but right now I’m focusing on getting it done rather than publishing it for other users.

    I just finished setting up my development environment and am just getting started with the free time I have.

    Thanks again for all your help and support, it is truly appreciated!

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    I am going to look if i can embed cropperjs into wppa. WOuld be a great new feature.

    As i understand you have no longer objections against using imagick?
    If i do this, i will have the possibility to crop the display image as well, because this would be the first thing other users will ask when they can crop thumbnails.

    I imagone the following workflow to crop a thumbnail:

    – crop the display file (the cropped image will still be large enough to make reduced size thumbnail form) with an imagick command, like all other imagick commands are executed on the display imae file.
    – remake thumbnail (from the cropped displayfile).
    – set a (new to implement) switch that locks the thumbnail against remaking (to cope with the remake all issue).
    – revert the imagick operation (like all other imagick operations are revertable if the source is available).

    Thread Starter davidlag

    (@davidlag)

    No objections at all to use ImageMagick!

    Thanks! πŸ™‚

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    Just an update: Cropping is going to work. I expect a working dev version in a few days.

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    Please test this version (beta):
    https://downloads.wordpress.org/plugin/wp-photo-album-plus.7.2.03.001.zip

    Either do a de-activate – activate, or, if you ftp the files directly, run Table VIII-A1 (Setup); this will update the db table wppa_photos to add the column ‘thumblock’.

    There is not a way to find the coverimages easy to edit them yet, but that will come soon.

    Its rather big now (15Mb) but i will seee what i can remove from …/wp-photo-album-plus/vendor/cropperjs/ and do so before the release.

    Thread Starter davidlag

    (@davidlag)

    I’ll be testing this new version shortly. I had to leave the city for the week for work and my days were quite packed. I’ll get back to you as soon as I can.

    Thanks a lot!

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    Dont hurry, i have still a lot to do on it, but little time currently. It will be great when ready. Stay tuned…

    Thread Starter davidlag

    (@davidlag)

    I just installed the new version. I can see the checkbox with “Locked” and the new column in the DB. I couldn’t find CropperJS in the plugin settings. Have you integrated it in the GUI yet?

    Plugin Author Jacob N. Breetvelt

    (@opajaap)

    I just committed
    https://downloads.wordpress.org/plugin/wp-photo-album-plus.7.2.03.004.zip

    this version should work correctly. Previous dev versions re-loaded the wrong images, and not all changing fields on the screen were updated; e.g. when you crop the image, the new display and thumbnail files are created, and the x, y and filesize change. This is now also being updated.

    As soon as you have defined a correct location for the external imagemagick commands in Table IX-K7, cropperjs will be loaded. The files used are the distributionfiles, the rest has been removed to save space. The files are in wp-photo-album-plus/vendor/cropperjs/

Viewing 15 replies - 16 through 30 (of 36 total)
  • The topic ‘Feature questions’ is closed to new replies.