Hi Please
Could someone tell me where I find the code that is creating the #av_section_1 which has the related and up sell products in it. I would like to move it please using woo commerce hooks, but i need to find the hook first to do so.
Thanks
Clyde Thomas
Hi Clydeo!
It sounds like your talking about line 957 in the /enfold/config-woocommerce/config.php file.
#
# 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', 'avia_woocommerce_output_related_products', 20);
function avia_woocommerce_output_related_products($items = false, $columns = false)
{
global $avia_config;
$output = "";
if(!$items) $items = $avia_config['shop_single_column_items'];
if(!$columns) $columns = $avia_config['shop_single_column'];
ob_start();
woocommerce_related_products(array('posts_per_page'=>$items, 'columns'=>$columns)); // X products, X columns
$content = ob_get_clean();
if($content)
{
$output .= "<div class='product_column product_column_".$columns."'>";
//$output .= "<h3>".(__('Related Products', 'avia_framework'))."</h3>";
$output .= $content;
$output .= "</div>";
}
$avia_config['woo_related'] = $output;
return $output;
}
Best regards,
Elliott