Skip to content

Instantly share code, notes, and snippets.

View sarangs07's full-sized avatar

Sarang Shahane sarangs07

  • Pune, Maharashtra.
View GitHub Profile
@sarangs07
sarangs07 / functions.php
Last active May 26, 2020 12:50
Add Event snippet for [HB] Compra General conversion page
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
add_action( 'wp_head', 'pp_add_event_code_in_head' );
@sarangs07
sarangs07 / functions.php
Created May 18, 2020 14:28
Redirect to Shop or any page if the Cart is empty.
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
add_filter( 'template_redirect', function (){
@sarangs07
sarangs07 / functions.php
Last active July 22, 2020 08:48
Change the add-to-cat button URL
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
/* Change the add-to-cat button URL */
@sarangs07
sarangs07 / functions.php
Last active July 16, 2020 13:11
Remove the specific CartFlows pages from the cache.
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
add_filter( 'cartflows_do_not_cache_step', 'cache_cartFlows_pages' );
@sarangs07
sarangs07 / functions.php
Last active April 30, 2020 06:29
Remove Avada Theme's conflict
/* Please add the below CSS into your customizer -> Under Additional CSS */
body.cartflows_step-template-default:not(.avada-woo-one-page-checkout) .woocommerce form.checkout #order_review,
body.cartflows_step-template-default:not(.avada-woo-one-page-checkout) .woocommerce form.checkout #order_review_heading,
body.cartflows_step-template-default:not(.avada-woo-one-page-checkout) .woocommerce form.checkout .col-2{
display:block;
}
@sarangs07
sarangs07 / functions.php
Created April 29, 2020 14:23
Remove order summary only from the CartFlows page.
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
add_action( 'cartflows_checkout_form_before', 'remove_order_summary' );
@sarangs07
sarangs07 / functions.php
Created April 27, 2020 13:56
Disable the Autocomplete zipcode on the CartFlows Checkout page.
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
@sarangs07
sarangs07 / functions.php
Created April 21, 2020 11:53
Load theme's styles & scripts even if the page template is for page builders
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
add_filter( 'cartflows_remove_theme_styles', 'th_load_theme_files' );
@sarangs07
sarangs07 / functions.php
Last active April 21, 2020 11:53
Remove the Revo Theme conflict
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
@sarangs07
sarangs07 / functions.php
Created April 15, 2020 13:23
Change the order status cron time
/*
* How to add the custome code.
*
* Please follow below instructions:
* 1. Copy the below code.
* 2. Open your child theme's functions.php file.
* 3. Paste the copied code at the very bottom of it & save the file OR upload it on your server/hosting.
*/
/**