WordPress.org

Ready to get started?Download WordPress

Forums

Slideshow Gallery
[resolved] Cant assign slides to galleries (5 posts)

  1. jonnymaboy
    Member
    Posted 1 year ago #

    I can create galleries and upload images, but when it comes to bringing the two together, nothing happens. I select the required gallery checkbox the image edit form and click Save but every image I've uploaded is still linked to zero galleries.

    In MySQL, there is the correct data in the below tables:

    wp_gallery_slides
    wp_gallery_galleries

    but no data exists in: wp_gallery_galleriesslides

    I can manually enter data into wp_gallery_galleriesslides and then things work, but obviously this is not a viable option.

    http://wordpress.org/extend/plugins/slideshow-gallery/

  2. gb2048
    Member
    Posted 1 year ago #

    Hi,

    I'm getting the same issue with 3.4.1 and also getting the sub-directory issue. Also the tables seem to be created with MyISAM instead of the default InnoDB engine.

    Please kindly fix as soon as possible.

    Thanks,

    Gareth

  3. gb2048
    Member
    Posted 1 year ago #

    Also using 1.2.2.1

  4. dad42kids
    Member
    Posted 1 year ago #

    I found this in another forum and it worked perfectly. Hope this helps.

    The problem lied within the insert query in the (whatever your wp table prefix is)_galleriesslides table.

    If you locate the db.php file within the helpers folders within the gallery slide plugin and find the following line:
    $galleryslidequery = "INSERT INTO" . $wpdb -> prefix . strtolower($this -> pre) . "_galleriesslides(id,slide_id,gallery_id,created,modified) VALUES ('', '" . $slide_id . "', '" . $gallery_id . "', '" . $date . "', '" . $date . "');";

    and change it to:

    $galleryslidequery = "INSERT INTO" . $wpdb -> prefix . strtolower($this -> pre) . "_galleriesslides(slide_id,gallery_id,created,modified) VALUES ('" . $slide_id . "', '" . $gallery_id . "', '" . $date . "', '" . $date . "');";

    You should be good. Insert queries cannot have blank or null values. the id was being set to nothing, so just removing it solved the issue.

  5. Antonie Potgieter
    Member
    Plugin Author

    Posted 1 year ago #

    Thank you for posting the solution @dad42kids

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic