Home › Forums › General Issues › Check if image size exists › Reply To: Check if image size exists
If the image size does not exist, usually because the original image is smaller then the defined image field then the full size image is returned.
When using wp_get_attachment_image_src() the return arrays 4th element will be true if the image at that size has been resized.
I do not know if this information about the image is returned in the image size details.
Find out
$theImage = get_sub_field('hero_image');
echo '<pre>'; print_r($theImage); echo '</pre>';
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.