This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter('retainful_premium_add_to_cart_collection_button_classes',function($classes){ | |
return array('add_to_cart_button_classes' => '.elementor-button-link'); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
These lines around line number 5472 | |
if ("" !== n && "" === $j(this).attr("href").split("#")[0] || "" !== n && "" !== $j(this).attr("href").split("#")[0] && n === window.location.hash || "" !== n && $j(this).attr("href").split("#")[0] === window.location.href.split("#")[0]) { | |
should be changed to something like: | |
var $href = $j(this).attr("href") ? $j(this).attr("href").split("#")[0] : ""; | |
if ("" !== n && "" === $href || "" !== n && "" !== $href && n === window.location.hash || "" !== n && $href === window.location.href.split("#")[0]) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body style="background: rgb(255, 255, 255);"> | |
<div class="mj-container" style="background-color:#fff;"> | |
<!--[if mso | IE]> | |
<table role="presentation" border="0" cellpadding="0" cellspacing="0" width="520" align="center" style="width:600px;"> | |
<tr> | |
<td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"> | |
<![endif]--> | |
<div style="margin:0px auto;max-width:600px;background:#00D2C2;"> | |
<table role="presentation" cellpadding="0" cellspacing="0" style="font-size:0px;width:100%;background:#00D2C2;" align="center" border="0"> | |
<tbody> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @package J2Store | |
* @copyright Copyright (c)2014-17 Ramesh Elamathi / J2Store.org | |
* @license GNU GPL v3 or later | |
*/ | |
// No direct access to this file | |
defined('_JEXEC') or die; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function add_woo_discount_rules_custom_script(){ | |
?> | |
<script> | |
function click_update_cart_btn(upd_cart_btn) { | |
var upd_cart_btn = jQuery(".fusion-update-cart"); | |
upd_cart_btn.trigger("click"); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//How to provide a tiered, cart subtotal based discount automatically in WooCommerce. | |
//The snippet assumes that you wanted to provide a fixed discount amount | |
function auto_apply_coupons_based_on_cart_subtotal() { | |
//NOTE: You must create the coupon codes first for these 5 tiers and replace the coupon code in the respective lines below | |
//$10 discount for purchases above $100 | |
$get1 = 'MYCOUPON10'; //your coupon code for $10 discount |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter('woocommerce_sale_flash', 'woocommerce_custom_sale_text', 10, 3); | |
function woocommerce_custom_sale_text($text, $post, $_product) | |
{ | |
return '<span class="onsale"> -10% </span>'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(!function_exists('fc_woo_applied_coupons_in_cart_html')) { | |
function fc_woo_applied_coupons_in_cart_html($coupon_html, $coupon, $discount_amount_html) { | |
$discount_name = 'discount'; | |
//apply only for virtual coupons of woo discount rules | |
if(isset($coupon->code) && strtoupper($coupon->code) == strtoupper($discount_name)) { | |
$coupon_html = $discount_amount_html; | |
} | |
return $coupon_html; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//The following snippet will be useful when you want to display the rule name instead of the standard Coupon: Discount | |
//while using the Woo Discount Rules plugin | |
if(!function_exists('woo_applied_cart_rules')) { | |
function woo_applied_cart_rules($cart_rules_object){ | |
global $applied_rules; | |
$applied_rules = array(); | |
if(isset($cart_rules_object->matched_discounts)) { | |
global $applied_rules; | |
$applied_rules = $cart_rules_object->matched_discounts; |