E-commerce Code Snippets
Here you'll find certain snippets to do some general common stuff in Themify themes. Note that some snippets might not work in all themes.
General procedure to use a snippet
1. Create a file named custom-functions.php in your theme root folder
2. Edit it, and paste this inserting the snippet you've chosen
3. Save the file. If you were editing it locally, upload it by FTP to the theme folder in your server.
When you already have a custom-functions.php, you only need to add the PHP code inside the <?php and ?> tags.
E-commerce themes: replace link to add to cart, with a link to product details.[code type=php] %s', get_permalink( $product->id ), esc_attr( $product->id ), esc_attr( $product->get_sku() ), esc_attr( $product->product_type ), __('Read More', 'themify') );
add_filter('woocommerce_loop_add_to_cart_link', 'custom_themify_woocommerce_loop_add_to_cart_link', 10, 3);