user3628794
user3628794

Reputation: 11

FishPig: Blog Category - Associated products not showing up?

I've successfully installed the Fishpig module and am able to display associations between products and posts / and vice-verse.

However, I am unable to display / output the associated products with the Blog Categories.

By default they did not show. So I've added the following code to /frontend/default/theme/layout/wordpress.xml:

<wordpress_post_category_view>
  <reference name="content">
    <block type="wordpress/category_view" name="wordpress_category" template="wordpress/category/view.phtml">
      <block type="wordpress/post_associated_products" name="wordpress_associated_products" as="associated_products" template="wordpress/post/associated/products.phtml" />
      <block type="wordpress/post_list" name="wordpress_post_list" as="post_list" template="wordpress/post/list.phtml">
        <block type="wordpress/post_list_pager" name="wordpress_post_list_pager" as="pager"/>
      </block>
    </block>
  </reference>
</wordpress_post_category_view>

and I'm trying to call the block via the /frontend/default/theme/template/wordpress/category/view.phtml

<?php echo $this->getChildHtml('associated_products'); ?>

This same technique works for the Blog Posts pages, but it doesn't seem to work for Blog Categories. Any ideas ?

Upvotes: 1

Views: 760

Answers (1)

Ben Tideswell
Ben Tideswell

Reputation: 1697

It isn't possible to show associations on a category page. The associations are stored in the database so you could achieve this using some custom code but by default, these associations are used to quickly associate all entities in the category.

As an example, if you associate a blog post with a Magento category, you are actually associating the blog post with all products in the Magento category.

Upvotes: 1

Related Questions