From c2fca1429a571a697833b946ec74ad4543a4fb03 Mon Sep 17 00:00:00 2001 From: Colin Marshall Date: Mon, 28 Aug 2017 13:06:30 -0600 Subject: [PATCH] Changed regex so it could only start with width or height. --- library/responsive-images.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/responsive-images.php b/library/responsive-images.php index a4363892c..cc04ae4fc 100644 --- a/library/responsive-images.php +++ b/library/responsive-images.php @@ -61,7 +61,7 @@ function foundationpress_adjust_image_sizes_attr( $sizes, $size ) { // Remove inline width and height attributes for post thumbnails function remove_thumbnail_dimensions( $html, $post_id, $post_image_id ) { if(!strpos($html, 'attachment-shop_single')) { - $html = preg_replace( '/(width|height)=\"\d*\"\s/', '', $html ); + $html = preg_replace( '/^(width|height)=\"\d*\"\s/', '', $html ); } return $html; }