1add_filter( "woocommerce_get_item_data", "cs_get_item_data", 10,2 );
2function cs_get_item_data( $data, $cart_item ){
3 if ( isset( $cart_item['singleFood'] ) ) {
4 $data[] = array(
5 'name' => 'Choosen Custom Food Items',
6 'value' => sanitize_text_field( $cart_item['singleFood'] ),
7 );
8 }
9 return $data;
10}
11