Hi,
REturn type is Image Array, but when I access the URL key in my local environment it’s set to my production url.
The urls in wp_options are updated to my local url so not sure where the URL in the image array gets the production url.
Any help?
Thanksm
The only thing that ACF stores is the ID of the image.
When getting the data ACF calls WP functions so this is what WP is returning. This means that somewhere on your site WP is finding the production URL for the site.
'url' => wp_get_attachment_url( $attachment->ID ),
'link' => get_attachment_link( $attachment->ID ),
https://developer.wordpress.org/reference/functions/wp_get_attachment_url/