vankaa
Forum Replies Created
-
Forum: Plugins
In reply to: [WooCommerce] Restricted Coupons not restricting.Can you provide steps to reproduce the issue? When tested, the feature works, it may be a certain case that you did hit and that does not work.
Forum: Plugins
In reply to: [WooCommerce] Woocommerce status change (emails)It is a new customer order, meaning that it is a new order from the customer not that it is a new customer that ordered. The heading/subject you can change in the Email settings for New Order email.
Forum: Plugins
In reply to: [WooCommerce] Exclude Categories from Related ProductsThe
$categoriesis array of term IDs not term objects. So the check for the id should look likein_array( $cat, $exclude_cats )Forum: Plugins
In reply to: [WooCommerce] Format of product tabsYes, you can do that with simple CSS. Just spread the UL to the full width and float the tabs with some width attached to them. Then style as you want.
You will have to write your own js to show/hide those.
jQuery(document).ready(function ($) { $('body').on('woocommerce-product-type-change', function () { if ($('select#product-type').val() == 'your-product-type') { $('.show_if_variable').show(); $('.hide_if_variable').hide(); $('.options_group.pricing ._regular_price_field').show(); } }); });Forum: Plugins
In reply to: [WooCommerce] Sync WooCommerce stageIt will depend on what your changes are, db, code, db and code.
Code you can just transfer to live and run. If population is needed, may be write an update script, something like the WC update process.
DB you should only migrate the changes, again with an update script.Backup > Maintenance mode > migrate.
Forum: Plugins
In reply to: [WooCommerce] problem with REST ApiThe error means that your request is not formed correctly. Check your json format. According to the message, you have an unmatched close bracket.
Forum: Plugins
In reply to: [WooCommerce] V3.2.1 404 CheckoutEnable WP_DEBUG, reload the page and look in the log. Does it have a “Fatal Error” in it?
Forum: Plugins
In reply to: [WooCommerce] Restricting Free Shipping Over a Certain AmountTry this:
apply_filters( 'woocommerce_shipping_free_shipping_is_available', 'prefix_is_available_up_to_max_amount', 10, 3 ); /** * @param bool $is_available * @param array $package Shipping package. * @param WC_Shipping_Free_Shipping $shipping_class * * @return bool */ function prefix_is_available_up_to_max_amount( $is_available, $package, $shipping_class ) { $max_amount = 200; $total = WC()->cart->get_displayed_subtotal(); if ( 'incl' === WC()->cart->tax_display_cart ) { $total = round( $total - ( WC()->cart->get_discount_total() + WC()->cart->get_discount_tax() ), wc_get_price_decimals() ); } else { $total = round( $total - WC()->cart->get_discount_total(), wc_get_price_decimals() ); } if ( $total >= $max_amount ) { $is_available = false; } return $is_available; }https://gist.github.com/vanbo/817a959c8c0c4cae3bc09d3e3532ce13
Forum: Plugins
In reply to: [WooCommerce] first price repeated down the listYou are probably changing the price from the global variable?
Instead, try using the'woocommerce_get_price_html'filter.Forum: Plugins
In reply to: [WooCommerce] Failed to Programmatically Update Woocommerce Cart TotalI would not recommend using the global $woocommerce, try using the WC() instead.
Try this for :add_action( 'woocommerce_calculate_totals', 'offer_book_calculate_total', 10 ); /** * @param WC_Cart $cart */ function offer_book_calculate_total( $cart ) { // WC > 3.0 $cart->set_cart_contents_total( 1.00 ); $cart->set_subtotal( 1.00 ); $cart->set_shipping_total( 1.00 ); // WC < 3.0 $cart->cart_contents_total = 1.00; $cart->subtotal = 1.00; $cart->shipping_total = 1.00; }- This reply was modified 8 years, 9 months ago by vankaa.
Forum: Plugins
In reply to: [WooCommerce] Add to cart variations failsHave you tried addint the variation to cart not the main product?
Forum: Hacks
In reply to: add_filter not workingYou have a typo for “apply_filters” declaration, you wrote it “apply_filter”, could this be your issue?
Forum: Fixing WordPress
In reply to: WordPress and Site Address Screw Up, Please HelpJust type ‘/wp-login.php’ after your domain name log in and revert your changes. And then read the info esmi provided.
Forum: Fixing WordPress
In reply to: Theme Atahualpa – Comment form headline/textI don’t know why you might not want to alter the css.php file since it only outputs the css styles directly on your page. This style is used only for the comments so nothing else will get altered.
To go to a certain line in a text document press ctrl+G and type the line number or for this case just search the style in the document.