Home › Forums › General Issues › Category Links › Reply To: Category Links
Thanks.
What I’m having trouble with is the code to use. ACF code.
Here’s what I tried that’s not working:
<?php if ( get_post_meta($post->ID, 'my_image', true) ) : ?>
<a href="<?php if ( get_post_meta($post->ID, 'my_image_link', true) ) : ?>"><img src="<?php the_field('my_image'); ?>" /></a>
<?php endif; ?>
This is what I’m having trouble with. When I add the ACF code to load the Taxonomy (which should be converted to a link, since the ACF Link field isn’t working for some reason) I’m not getting a real link, I’m getting a link to a number that goes nowhere.
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.