Remove Content Blocks from Learn Dash Courses
Important: You can now do this via the WordPress Customizer, no need for a custom snippet!
Important: You can now do this via the WordPress Customizer, no need for a custom snippet!
add_filter( 'woocommerce_single_product_carousel_options', function( $options ) { $options['slideshow'] = true; // enable auto slideshow $options['slideshowSpeed'] = 2000; // time in millesecond between slides return $options; }, PHP_INT_MAX );
The Navigation Menu widget accordion by default triggers dropdowns when clicking on the whole parent item, however, if you want to make the parent item also accessible so that only clicking on the arrow triggers the dropdown all you need…
When using header sytle one by default the theme adds javascript so that your megamenu expands full-width so it's always the width of your header. However, you can easily disable that via the code below added to your child theme's…
Every Total grid module for the page builder includes filters for each "section" so you can customize the output. For example if you insert the Post Type Grid there is a filter applied to the featured image, title, excerpt, button...etc…
function myprefix_edit_woo_price( $price, $product ) { if ( ! $product->is_in_stock() ) { $price = 'Sold'; } return $price; } add_filter( 'woocommerce_variable_sale_price_html', 'myprefix_edit_woo_price', 10, 2); add_filter( 'woocommerce_variable_price_html', 'myprefix_edit_woo_price', 10, 2); add_filter( 'woocommerce_get_price_html', 'myprefix_edit_woo_price', 10, 2);
add_action( 'wp_head', function() { ?> ( function( $ ) { $( document ).ready(function() { var images = ['image_url_1', 'image_url_2', 'image_url_3']; $( 'body' ).css( { 'background-image': 'url(' + images[Math.floor(Math.random() * images.length)] + ')' } ); } ); } ) ( jQuery…
If you want a specific product to be added to your cart automatically when another product is added you can do this with a little code in your child theme by hooking into the 'woocommerce_add_cart_item_data' hook and checking for the…
add_filter( 'wp_get_object_terms', function( $terms ) { if ( $terms ) { $excluded_terms = array( 100, 40 ); // array of term ID's to exclude foreach( $terms as $key => $term ) { if ( in_array( $term->term_id, $excluded_terms ) ) {…