ACF in header for Woocommerce product Category pages
-
Hello,
I am trying to insert banner between header and breadcrumbs in my product category page. Every category will have different banner. So I added a field with rules : taxonomy is equal Category(prod_cat). A field is also generated.But when adding php code : get_field and the_field, the banners are not displaying on the frontend.
if( is_product_category() ) { if(get_field('banner')){ the_field('banner'); } }
Adding this in header is not working. Please help how to get the banner displayed at top.
- The topic ‘ACF in header for Woocommerce product Category pages’ is closed to new replies.