UPDATE:
Now seems to be working (code used – https://gist.github.com/ChromeOrange/9486596 ).
FYI did three things.
WC>System Status>Tools>Clear Transients. (Checked after and no change).
Cleared Basket – re added items. (Checked after and no change).
Re-Updated the Variable Product with Heavy Shipping Class applied. (This seemed to do it, though think it may have been a combination of all three as would have obviously updated\saved product when originally applying the Shipping Class?)
Shipping gets cached so they may have all worked 😀
When debugging shipping, use WC > System Status > Tools > Shipping debug mode. it disables cache.
Hi,
I have also a problem with Shipping classes. Write to you here guys in case you can help by any chance.
There’s definitely a bug in this version 2.4.6 and shipping classes. All my products are with individual shipping classes with assigned price to them. After the update to the new version I notice that it shows message for “There Are No Shipping Methods Available.”
Only if I enter a basic overall value, it will show delivery costs in the cart.
I tried fidling with the settings, but no hope settling the issue in other way.
Juddi22 enter 0 for the main cost, if you only have class costs.
Not sure if I should resurrect this here (just tell me if I’m wrong to do so) but I’ve updated Woo to 2.6.0 which has rejigged Shipping and the gist code (https://gist.github.com/ChromeOrange/9486596) no longer works.
Any pointers? Many thanks for any help.
“available_methods” in that snippet may need adapting if the new methods you have, have different names e.g. they may now contain the instance ID. This will differ on every install.
Yes, I can see the various instance IDs… not sure how to add those IDs into ‘available_methods’ instead of using the slug (I’m no coder). I will have a go though and update if I find the solution. Many thanks for the pointer.
You can var_dump() the $available_methods
to see whats set perhaps. That will give you the names.
OK, great thanks Mike. Worked it out. To anyone else, posting the below to help.
I amended part of the original code https://gist.github.com/ChromeOrange/9486596 to below. I removed the var_dump comment to see on the front end what is used and find the names (note; you’ll need to check instance ID as will be different). Then I Unset as normal (though I needed to add two in as I’ve got free delivery in more than one zone). Hope this helps.
// Developers!: Dump this to see what you can unset
// var_dump( $available_methods );
// Unset Free Shipping if necessary
if( $freeshipping == false ) {
unset( $available_methods['free_shipping:5'], $available_methods['free_shipping:6'] );
}