Home › Forums › General Issues › Category images › Reply To: Category images
The wp_get_attachment_image() function will work if you actually put your values in the function. Currently, you have $image = wp_get_attachment_image_src( $attachment_id, $size );
but you need to have something like $image = wp_get_attachment_image_src( 39, 'name_of_size' );
. Also, your get_field function doesn’t seem correct. I would read more into the documentation about how to use get_field.
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.