You might try something like this in your functions.php
:
//remove class from the_post_thumbnail
function the_post_thumbnail_remove_class($output) {
$output = preg_replace('/class=".*?"https://wordpress.stackexchange.com/", '', $output);
return $output;
}
add_filter('post_thumbnail_html', 'the_post_thumbnail_remove_class');
Related Posts:
- How to create thumbnails with a fixed width, so all of them will have the same width?
- Setup A Default Featured Image
- Download an image from a webpage to the default uploads folder
- Remove images (files) that were generated when using add_image_size()
- Is there a hook which fires after all thumbnails are generated?
- Featured image shortcode
- How to find attachment by it’s name?
- Change WordPress image URLs via filter
- get_the_post_thumbnail_url with an unregistered size
- Cropped featured image replaces original image in gallery
- Any easy way to automatically set the first inline image in a post as the thumbnail?
- Change html structure of all img tags in WordPress
- Adding HTML within an image title attribute
- Programatically creating image attachments from local URLs and setting featured image
- How can I add the “Use as featured image” to a custom metabox?
- set_post_thumbnail_size not cropping featured images, but reducing proportionally
- Is it possible to prevent users from uploading small images?
- Can’t Display Featured Image in RSS Feed
- How to output placeholder image if no featured image set?
- Featured Images on Front Page
- Find posts without featured image? [duplicate]
- How do I add a featured image to a single post page?
- Add a featured image in my theme?
- Disable wordpress image sizes generation
- What’s the best “insert all images” plugin?
- Featured Image .svg height and width 1px only
- Images are randomly deleted from server
- Frontend Post – Allow Only Image File Upload
- Images not working using Featured post
- Add instructions to featured image
- How do I get more image editing options in the admin?
- Lazyload post thumbnails
- How can I make all post image uploads have data-width and data-height attributes automatically by default?
- Exclude featured image from gallery in wp-admin
- Photography Based Design – Multiple Images Per Post
- Woocommerce featured image of page – not product
- Can’t seem to attach uploaded image to post and set it as thumbnail
- Big Image on Featured Post, Normal on Single Post
- offload media to external services [closed]
- Store Snapshot created via wordpress to use with lightbox
- How do I Add images uploaded in the post to a default custom field
- How to stop thumbnail generation from some images and different size thumbnail generate
- Update old Post image metadata to ‘thumbnail’ wp_attached_file
- How to stop wordpress always displaying full-res images
- Get ALT attribute from title post (code not work)
- WP keeps looking up post thumbnail on https even though wp-config says http
- WordPress PNG compression issue
- How to replace images?
- Custom Loop, Match Category with Page: How to display post featured image?
- Redirect to another page using contact form 7? [closed]
- How to check for images before echo
- How do I get my main image to stretch the full length of the screen?
- Remove height attribute from wp_get_attachment
- Custom responsive ‘featured image’ sizes
- Images give 404 after changing default domain
- Featured Image If Else Condition
- Retrieve Image Attachments Getting Post Thumbnail Image First
- How to display original unmodified thumbnail
- How to set featured image from external url programmatically
- Hide Featured Image box – isn’t working?
- Show (print) featured image all dimensions (height, width)
- Serve different images per screen size and cache possible?
- Set two default featured images
- Product Images Low Quality After Updating From WP 3.5 to 4 [closed]
- adding image to post thumbnail from another server
- Set Featured Image not opening – Stuck at loading
- Apply nextgen-gallery lightbox effect [closed]
- Convert featured images into “product images”
- resize and crop thumbnail photos
- How to use the thumbnail size with catch_that_image
- my featured image of wordpress are not showing in the front end though image are uploaded in media library
- Custom image size not displaying with wp_get_attachment_image()
- How to use default image as featured image by implement some code in function.php
- WordPress Multisite: Images moved to /sites/1?
- How to delete original image file after upload and resize
- attachment_fields_to_save first parameter is null
- Show featured image in all posts
- Image alt attribute
- How to make image uploads default to full size?
- I cannot upload images to post or the media library in wordpress
- Images missing from Blog post page
- Custom Background for each page and post
- WordPress 404 Images – Images not found after deleted from media
- second featured post not displaying on page [closed]
- Delete post if featured image is smaller than Y pixels by Y pixels
- Url link to feature image in the portfolio [closed]
- How to add multiple images in a page
- Only User Upload image Http Error
- How do I get resized thumbnails?
- Making a thumbnail if there exist a link with. jpg or .png extension in WordPress
- Why is WordPress loading a different sized post thumbnail?
- Title image is missing ( but is not the WP 3.5 issue )
- Images will not attach to posts after site migration
- Why images are disappearing on WordPress web site?
- Using the on-board image editor for featured images: edits are not being used
- Img alt tag showing different value then entered
- Tried everything but Facebook share button won’t load the post thumbnail
- WP is showing wrong image dimensions
- Why some images are not allowed to be edited only for thumbnails?
- Edit multiple posts featured image