This file contains hidden or 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 //Do not copy this line of code | |
add_filter('woocommerce_order_number', 'wt_show_old_order_number', PHP_INT_MAX, 2); | |
function wt_show_old_order_number($order_number, $order) | |
{ | |
if ($order instanceof WC_Order) { | |
$meta_value = $order->get_meta('_order_number'); | |
if ($meta_value) { | |
$order_number = $meta_value; | |
} |
This file contains hidden or 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 //do not copy this line of code | |
add_action('woocommerce_before_single_product', function(){ | |
if(function_exists('is_product') && is_product() && class_exists('Wbte_Gc_Gift_Card_Free_Common')) | |
{ | |
global $product; | |
if(!empty($product) | |
&& method_exists('Wbte_Gc_Gift_Card_Free_Common', 'is_gift_card_product') | |
&& method_exists('Wbte_Gc_Gift_Card_Free_Common', 'is_templates_enabled') | |
&& Wbte_Gc_Gift_Card_Free_Common::is_gift_card_product($product->get_id()) |
This file contains hidden or 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
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko; CookieYesbot/1.0; +http://www.cookieyes.com/documentation/cookieyesbot) Chrome/131.0.6778.0 Safari/537.36 |
This file contains hidden or 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 //do not copy this line of code | |
add_filter('wtst_webhook_sleep_time', 'set_webhook_sleep_time'); | |
function set_webhook_sleep_time($time) { | |
return 0; | |
} |
This file contains hidden or 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> //Do not copy this line of code | |
add_action('wp_footer',function(){ | |
?> | |
<style> | |
.wt-related-products .owl-theme .owl-nav { margin-top: 25px !important; } | |
</style> | |
<?php | |
},10); |
This file contains hidden or 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>//Do not copy this line of code | |
add_filter('wt_iew_importer_do_import_basic', 'filter_products_by_brand', 1, 4); | |
function filter_products_by_brand($data_arr, $to_process, $step, $selected_template_data) { | |
// Define allowed brands (normalized to uppercase and trimmed) | |
$allowed_brands = array_map('strtoupper', array_map('trim', array('Brand1', 'Brand2', 'Brand3'))); | |
foreach ($data_arr as $key => $product) { | |
if (isset($product['meta_mapping_fields']['taxonomies']['tax:product_brand'])) { | |
$raw_brand = $product['meta_mapping_fields']['taxonomies']['tax:product_brand']; |
This file contains hidden or 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> //Do not copy this line of code | |
add_action('wp_footer', function () { | |
if (is_product()) { | |
?> | |
<script> | |
jQuery(document).ready(function () { | |
const container = jQuery('.wt-related-products'); | |
if (container.length > 0) { | |
const h1 = container.find('.wt-crp-heading'); | |
if (h1.length) { |
This file contains hidden or 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>//Do not copy this line of code | |
add_filter( 'wt_smart_coupon_display_invalid_coupons', '__return_false' ); | |
add_filter( 'wt_sc_alter_user_coupons', 'wbte_sc_remove_applied_coupons_from_user_coupons' ); | |
if ( ! function_exists( 'wbte_sc_remove_applied_coupons_from_user_coupons' ) ) { | |
/** | |
* Remove applied coupons from user coupons list | |
* | |
* @param array $post_ids Array of coupon post IDs. |
This file contains hidden or 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 //Do not copy this line of code | |
add_action('wp_footer', function () { | |
if (is_product()) { | |
?> | |
<script> | |
jQuery(document).ready(function () { | |
const container = jQuery('.wt-related-products'); | |
if (container.length > 0) { | |
const h2 = container.find('.wt-crp-heading'); | |
if (h2.length) { |
This file contains hidden or 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> //Do not copy this line of code | |
add_filter('wf_pklist_alter_template_html', 'wt_remove_tax_items_row_from_invoice', 10, 2); | |
function wt_remove_tax_items_row_from_invoice( $html, $template_type ) { | |
if ( $template_type === 'invoice' && strpos( $html, 'data-row-type="wfte_tax_items"' ) !== false ) { | |
// Only run regex if pattern likely exists | |
$html = preg_replace( | |
'/<tr[^>]*data-row-type="wfte_tax_items"[^>]*>.*?<\/tr>/is', | |
'', | |
$html | |
); |
NewerOlder