Tag Archives: wp_get_attachment_image


Get an HTML img element representing an image attachmentWhile $size will accept an array, it is better to register a size with add_image_size() so that a cropped version is generated. It’s much more efficient than having to find the closest-sized image and then having the browser scale down the image.


Continue reading