Sunset-theme
Sunset-theme copied to clipboard
gallery post format thumbnail issue when loaded from Ajax
The Post "gallery" doesn't behave normally, there is another issue here: the thumbnails don't show when the gallery post format is loaded using the loading button, however, if the post is showing on the page without loading i.e. the posted limit per page allows it, or the particular page which contains the post is refreshed, then it works fine,
Suggested Solution
adding the following piece of code inside the setTimeout function which is present inside the success portion of the Ajax function:
/*reveal carousel thumbnail after ajax loading*/
$( carousel ).on('slid.bs.carousel', function(){
sunset_get_bs_thumbs( carousel );
});
sunset_get_bs_thumbs( carousel );
Please note
this piece of code should be added outside any if-else functions, right where the revealPosts(); function was added