Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, and has everything to do with the woocommerce_output_related_products_args() filter: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tagshttps://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, and has everything to do with the woocommerce_output_related_products_args() filter: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, and has everything to do with the woocommerce_output_related_products_args() filter: https://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

added function name for context
Source Link
Nathan Powell
  • 1.6k
  • 1
  • 13
  • 31

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, but I do not have sufficient cloutand has everything to up votedo with the woocommerce_output_related_products_args() filter: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, but I do not have sufficient clout to up vote: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, and has everything to do with the woocommerce_output_related_products_args() filter: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags

Source Link
Nathan Powell
  • 1.6k
  • 1
  • 13
  • 31

Let's not fool ourselves here guys. The accepted answer only got the user to his goal.

The very first problem lies here:

<?php
// display upsells and related products within dedicated div with different column and number of    products
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products',20);
remove_action( 'woocommerce_after_single_product', 'woocommerce_output_related_products',10);
add_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20);

An action is removed, and then placed in the EXACT position it was removed from. The goal is completely unclear.

I came across this with a search on the related products because I did not understand that TAGS and CATEGORIES are what drives the woocommerce_output_related_products function in this plugin.

The best answer to THIS question is the following link, but I do not have sufficient clout to up vote: http://stackoverflow.com/questions/23554993/output-posts-relating-to-the-tags