I've got a custom publish type known as "Recommendations." I in addition have a custom taxonomy known as "Items," where each term is really a different product, like "Product A", "Product B", etc. By doing this, I'm able to fasten a testimonial to some specific product.

I am attempting to list my recommendations on a single page, but arranged by product. ("Recommendations for Product A," etc.)

I've got a bit of code that work well for groups, and so i transformed it to taxonomies:

$taxonomies = get_taxonomies('');
foreach ( $taxonomies as $taxonomy ) :

$args = array(
'posts_per_page' => 5,
'taxonomy' => $taxonomy->term_id,

if (have_posts()) :
echo '<h2>Latest Testimonials for '.$taxonomy->name.' Product</h2>';
while (have_posts()) : the_post(); ?>       

<?php the_content(); ?>

<?php endwhile; ?>
<?php else :
echo '<h2>No Testimonials for '.$taxonomy->name.' Product</h2>';
endif; wp_reset_query; ?>

<?php endforeach; ?>

Understandably, it does not work. Where shall we be held failing?