c.note
Member
Posted 6 months ago #
When a users deletes the an image from the user library without removing it as the secondary post thumb, a new image cannot be added. It just stays blank but the meta value in the wp_postmeta table has the old image reference in it. This is quite a critical bug as the only way to rectify it is to remove the record in wp_postmeta table.
http://wordpress.org/extend/plugins/multiple-post-thumbnails/
turtlepod
Member
Posted 5 months ago #
is there a way to solve this?,..
lonchbox
Member
Posted 5 months ago #
Hi there, Any news if this going to be solved ?
Chris Scott
Member
Posted 5 months ago #
Please try this version of the plugin: http://plugins.svn.wordpress.org/multiple-post-thumbnails/trunk/multi-post-thumbnails.php
WARNING: Be sure to back up your database first and/or use this on a test installation. I've tested this with a few different configurations, however, since it does a delete on database rows, better safe than sorry.
gabrielperezs
Member
Posted 5 months ago #
Hi, to solved this without going to the database I do this modification on the functión set_thumbnail:
if (!empty($thumbnail_html)) {
delete_post_meta($post_ID, "{$this->post_type}_{$this->id}_thumbnail_id");
update_post_meta($post_ID, "{$this->post_type}_{$this->id}_thumbnail_id", $thumbnail_id);
die($this->post_thumbnail_html($thumbnail_id));
}
Apply the "delete_post_meta" before "update_post_meta". This fix the problem when you remove and image from the media and not in the post.
c.note
Member
Posted 5 months ago #
The script has been updated by the author, Chris Scott.