1$rate_table = array();
2
3$shipping_methods = WC()->shipping->get_shipping_methods();
4
5foreach($shipping_methods as $shipping_method){
6 $shipping_method->init();
7
8 foreach($shipping_method->rates as $key=>$val)
9 $rate_table[$key] = $val->label;
10}
11
12echo $rate_table[WC()->session->get( 'chosen_shipping_methods' )[0]];
1$shipping_classes = get_terms( array('taxonomy' => 'product_shipping_class', 'hide_empty' => false ) );
1# WOOCOMMERCE SHIPPING METHOD
2
3function name_1() {
4
5// Add a new class here
6
7}
8
9add_action( 'woocommerce_shipping_init', 'name_1' );
10
11Check on source site for more update and method
12