Hi,
I have a custom post type (lets call it “Products”) and a custom taxonomy (lets call it “Designers”).
I want to create a custom field that allow me to choose an image for this taxonomy. So when you visit “www.site.com/deisgner/designer1” you will se this image in the archive-description.
I have made a custom field group with 1 field (image-field) and it is set to be shown when the taxonomy term is equal to “Designer”.
I have chosen an image on the “designer1” taxonomy page and saved it.
This is the code from my functions.php:
function show_tax5(){
?>
<div>
<img src="<?php the_field('archive_image'); ?>" />
</div>
<?php
}
add_action('hook_top_archive','show_tax5');
But when I visit the “designer1” page it shows no image. All it shows (in the code) is <img src>
What am I doing wrong?