It seems that if the default images sizes have been changed, then there will be an instance when the item.sizes.thumbnail
will be underfined.
I ended up building in a check for this and if thumbnail was not defined, then I use the original image instead
Related Posts:
- Using the WordPress 3.5 Media Uploader window as a modal popup
- Change Media modal image size
- How to let a user select a media from the media library
- Media Modal not updating with file upload
- Media modal in IE9 not working when included from plugin with wp admin scripts minified
- Is there a native wp.media way to detect who “opened” wp.media.frame
- Use wp.media templates to create totally custom modal
- Bootstrap Modal isn’t working in WordPress Plugin with Template Avada [closed]
- foundation 4 reveal popup pass a variable
- Trigger refresh for new media manager in 3.5
- How to trigger a refresh in the media modal
- List of available events for wp.media
- ThickBox replacement
- WordPress 3.5 Media Manager – add a button
- Rendering the uploaded file in a wp.media object
- Best approach when modifying the Media Manager
- Custom “Uploads” Dir: “Edit Image” in Media Library broken
- Customizing the 3.5 “Add Media” popup (Backbone.js)
- How to restrict images in v3.5 Media Library modal to only those from a specific post id?
- Expanding new Media Uploader in WordPress 3.5
- Filter media library items by size
- Modifying the media-template.php file, the right way?
- Disable media library tab for non admins in uploader screen
- Refresh wp.media after ajax call
- ‘Add Media’ button doesn’t work when editor is initialized from javascript
- Add control in image detail panel
- Hook for image edit popup
- How do I add the data-toggle=”modal” data-target=”#myModal” attribures to a WP Nav bar?
- What type of template are WP media-modal’s templates?
- Wp3.5 Media Gallery Edit modal: change captions to title
- Modify Custom Field in Media Library using JavaScript
- Modify the array of selected images in media modal
- Media manager multiple selection
- How to extend Media Library (WP 4.4)
- How to set additional parameter in wp.media?
- Adding fields to the media uploader with jquery listeners
- Open the attachment details modal
- Trying to add filename over image in Media Browser
- Filter medias from the Media Uploader (wp.media) modal with a post meta
- Run script after clicking Set Featured Image in Media
- Category checkboxes in upload modal
- Upload images from custom plugin using the media modal
- Adding image to visual editor popup for shortcode with wp.media and wp.mce: changing image duplicates shortcode
- trigger(‘change’) not working
- Perform a custom (bulk) action in media view
- Add guid filter to attachment in media library grid mode
- WordPress 3.5 Media Manager – add a button
- Show selected images on top in Media Manager
- WordPress Built In Dialog Box For My Plugin
- How to check an ajax nonce in PHP
- Only displaying zip files with wp media
- Lightbox Plus ColorBox plugin and auto playing YouTube video
- admin_enqueue_scripts not working
- Is it possible to hide media details sidebar when wp.media popup is being opened?
- Media upload not working on theme option in WordPress 3.8.1
- Adding Media Upload to Custom Options Panel breaks “Insert into Post”
- Calling WP Gallery Uploader/Selector From Metabox
- How to enable sorting in custom media uploader in plugin
- WordPress 4.9.8 Trying to add filename over image in Media Browser
- How to submit data between wp_iframe and backbone.js in media upload
- How to get the return value of wp.media({ frame: ‘post’ }) in all cases?
- How to open the add media dialogue it in a certain state / tab?
- Show media-frame-menu on custom Media Frame
- Set post_parent value for the images uploaded by Add Media button into post
- Get File Object from wp.Uploader
- Show error, when selecting image in WordPress media uploader if params mismatch
- Passing jQuery into the WordPress media uploader
- Capability to prevent upload of files
- Extending wp.media.model, query media from different blog on network and refresh view
- 3.8 Media Upload and Custom Meta Box
- Opening a JQuery modal window on click of a button with a JQuery plugin
- admin notice on Insert Media popup screen
- Set a minimum and maximum limit of images to select in the MediaUpload component for Block
- Launch Media Library for specific MU site
- Query data after an Ajax insert
- Modal dialog under the backdrop
- Display WP Meta Details in Bootstrap Modal
- Insert HTML markup to page content from the Media Frame modal
- Media Library modal customization
- overwrite wordpress gallery with custom gallery shortcode
- JQuery modal not loading video on popup, only displaying it after multiple reopenings
- Forbidden permission and editor error after update to WordPress 5.1.1
- Modal opens all post IDs
- WordPress Media Uploader : How to add custom button on featured image tab
- Creating custom setting in add media popup
- WordPress Dropdown image select
- Changed media upload path for plugin, but generates error & shows wrong url
- update_user_meta inside a popup/modal
- How to destroy or dispose wordpress uploder/manager?
- wp_enqueue_media(); in multiple widgets
- Displaying a specific sub-category’s posts from wp_query
- WP Media Uploader modal conflicts with Bootstrap modal
- Removing delete permanently button in uploading files media
- Get URL of current featured image with JS in edit post view
- Why doesn’t WordPress make thumbnails for videos?
- WordPress Media manager select file button, how to prevent hiding?
- Insert into post or
- Remove Edit Attachment Button in WordPress Mediathek -> see Screenshot
- How to add extra EXIF data when images are uploaded?
- Is there any halfway decent documentation on the wp.media JS class?