Home Forums Front-end Issues Display field of product on category/archive


Display field of product on category/archive

  • Hi there,

    I am desperately trying to display some extra fiels on the product cards of category/archive pages, like is being done here:

    First of all the question: Can I put code related to WooCommerce in my child-theme functions file?

    I have been experimenting and here is my end result:

    /**ACF FIELD
    add_action( ‘woocommerce_after_shop_loop_item’, ‘acf_velden’, 10 );

    function acf_velden() {

    if( get_field(‘drukopties’) ):
    echo ‘<p>Drukopties:’ get_field(‘drukopties’) .'</p>’;

    The field ‘drukopties’ is a checkbox which has to be filled in from the backend and needs to display the checked values on front end.

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.