add_action('thematic_searchloop', 'mytheme_search_loop');
// End of the Contextual/Highlight Search functions
+// declare Woocommerce support
add_action( 'after_setup_theme', 'woocommerce_support' );
function woocommerce_support() {
add_theme_support( 'woocommerce' );
}
+/**
+ * Change number of related products output
+ */
+function woo_related_products_limit() {
+ global $product;
+
+ $args['posts_per_page'] = 3;
+ return $args;
+ }
+ add_filter( 'woocommerce_output_related_products_args', 'related_products_args' );
+ function related_products_args( $args ) {
+ $args['posts_per_page'] = 3; // 4 related products
+ $args['columns'] = 3; // arranged in 2 columns
+ return $args;
+ }
+
// The GLM Simple Messageboard needs this function to display its data
if ( !function_exists( 'glm_get_simplemessageboard_option' ) ) {
function glm_get_simplemessageboard_option( $option_name )