• Resolved davidallen23

    (@davidallen23)


    Hi
    I’m very new at this so please bear with me.
    I’m building a site for photo galleries – no blogs.
    Tried quite a few plugin galleries & finally settled on WP Photo Album Plus.
    I set up a couple of test albums and it seemed to work OK so I decided to start afresh – empty the Media library, upload some more images, create a new album, import photos. Then it all went screwy.

    Suppose I had 4 photos in the Media library – filenames img1.jpg, img2.jpg, ing3.jpg & img4.jpg. I import them into an album and via the album the filenames are correct but the photos are not the right ones.

    Because I’d been testing a variety of gallery plugins for a while, uploading, importing, deleting Media etc. I figured something had gone pear-shaped along the the way so I deleted the WP Photo Album Plus plugin, emptied the media library and started afresh.
    It’s still doing the same thing – filenames are correct in album – pictures are the wrong ones.
    Any suggestions would be most welcome.

Viewing 8 replies - 1 through 8 (of 8 total)
  • How did you delete the photos? You should never remove the files manually from disk, you should use the delete function on the album admin pages.

    If you want to start from scratch, you will have to drop table the photo and album tables.

    You can do this by changing the function wppa_setup() in the file wppa-setup.php:

    the start reads:

    function wppa_setup($force = false) {
    	global $wpdb;
    	global $wppa_revno;
    	global $current_user;
    
    	$old_rev = get_option('wppa_revision', '100');
    
    	if ( $old_rev >= $wppa_revno && ! $force ) return; // Nothing to do here
    
    	$create_albums = "CREATE TABLE " . WPPA_ALBUMS . " (
    					id bigint(20) NOT NULL,
    					name text NOT NULL,

    change it to:

    function wppa_setup($force = false) {
    	global $wpdb;
    	global $wppa_revno;
    	global $current_user;
    
    	$old_rev = get_option('wppa_revision', '100');
    
    	if ( $old_rev >= $wppa_revno && ! $force ) return; // Nothing to do here
    
    $wpdb->query("DROP TABLE " . WPPA_ALBUMS);
    $wpdb->query("DROP TABLE " . WPPA_PHOTOS);
    
    	$create_albums = "CREATE TABLE " . WPPA_ALBUMS . " (
    					id bigint(20) NOT NULL,
    					name text NOT NULL,

    After that, check the radiobutton in the Settings screen: Table VIII item 3 and press Save Changes.

    After that REMOVE THE MODIFICATION!!!! Otherwise your tables will be lost again after an update.

    A second thought:

    Maybe it is not so dramatically.

    I hope you are up to rev (4.2.1)
    Go to the Photo Albums -> Settings screen and check radiobutton Table VIII item 9: Cleanup and press Save Changes.

    Then go to the Photo Albums menu and delete the albums and/or photos you want to get rid of.

    Then, before continuing uploading or importing new photos: THROUGHLY CLEAR YOUR BROWSER CACHE.

    The photo id’s may be re-used after deleting, so when you add new photos, your browser may have the old ones still in cache.

    Thread Starter davidallen23

    (@davidallen23)

    Thanks for your reply.
    ‘How did you delete the photos?’
    I deleted the photos via Media/Library Bulk Delete option.
    Afterwords, and before I’d uploaded more, I used the WP Photo Album Plus Import option to check that all photos had in fact been deleted.
    I was puzzled to find that there were still about a dozen there!
    Going by the file names they looked like thumbnails – instead of 1000.jpg there were 1000-250×166.jpg! There appeared to be no way to delete those.

    As far as ‘changing the function wppa_setup() in the file wppa-setup.php’ this, for me is dangerous territory. As I said, I’m pretty new at this.
    So, I’ve been into the server end and found the file ‘wppa-setup.php’ but there is nothing in there that looks remotely like your instructions.

    In the meantime I’ve batch renamed all my photos to entirely different filenames, uploaded them and imported them to a WP Photo Album Plus album. There were a couple of files there that had the correct filename but the wrong picture. After deleting them and re-importing them things seem to be working fine.

    Whilst investigating the server files I’ve found a folder containing the old problematic pictures/file names. They are located at:
    Public_html\wp-content\gallery\streets\
    (Streets was an album name I was using which I’ve now deleted from the front end of WP Photo Album Plus).
    Would it not be OK to delete these files from the server end just to clean things up or should I leave well alone?

    Thread Starter davidallen23

    (@davidallen23)

    Apologies. Missed your second post whilst composing my previous but as you see, things have moved on a tad.

    Thread Starter davidallen23

    (@davidallen23)

    Thanks for your help.

    I think you are mixing up the regular wp gallery images and the wppa+ photos.

    The latter are in wp-content/uploads/wppa/ and in its subdir thumbs/

    You can however easy import regular wp images into wppa+, See the Import photos admin page, and select a location in Import photos from:

    Thread Starter davidallen23

    (@davidallen23)

    Well, I just went for the default directory when importing so how they ended up somewhere else I don’t really understand and as I’ve tried and discarded so many methods of creating a gallery/slideshow in the past week I guess it’s not suprising things got into a bit of a mess.
    Regardless, I now have the whole thing up and running so…
    It’s here: https://www.gamlingayphotos.co.uk/
    Once again, thanks for your help.

    I have seen it. Great!. You’re always welcome for questions.
    Would you please change this topic to ‘resolved’?

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Media Library/WP Photo Album Plus problems.’ is closed to new replies.