Sum the total amount of a specific product purchased per user and display in table
WooCommerce: Get Order info for all users. I was trying to help you get going.. After a while i had a complete solution :S… So here it is, a tested single shortcode that outputs your <table> (WooCommerce 3+ only): add_shortcode(‘user_order_info_table’, ‘sc_user_order_info_table_callback’); function sc_user_order_info_table_callback() { $result_array = array(); $users = get_users(); if($users) { foreach ($users as … Read more