Viewing 8 replies - 16 through 23 (of 23 total)
  • Plugin Author FullStack-ing

    (@fullstackhouse)

    add this please (remove the old one)

    
    add_filter( 'wc_smart_cod_fee', 'change_cod_price' );
    
    function change_cod_price( $price ) {
      if( is_numeric( $price ) && intval( $price ) === 0 ) {	
        return $price;
      }
      return $price < 3 ? 3 : $price;
    }
    
    • This reply was modified 4 years, 7 months ago by FullStack-ing.
    Thread Starter cigno76

    (@cigno76)

    old removed.
    unfortunately, for amounts less than 3 euro it does not set 3 euro again.

    Plugin Author FullStack-ing

    (@fullstackhouse)

    Please send me a screenshot of your plugin settings

    Thread Starter cigno76

    (@cigno76)

    Hello,
    the screenshots below

    https://veroliolivo.it/support/

    Plugin Author FullStack-ing

    (@fullstackhouse)

    Hi again! I just checked with a similar configuration and it works as it should.

    Please make sure you copy pasted the above block code correctly, you don’t left anything from the previous block codes I sent you, and that you don’t use any other plugin to manipulate COD.

    If the problem still persists you could try that:

    
    add_filter( 'wc_smart_cod_fee', 'change_cod_price' );
    
    function change_cod_price( $price ) {
      if( $price === '0' ) {	
        return $price;
      }
      return $price < 3 ? 3 : $price;
    }
    

    But as I told you before, the previous snippet works just fine (sets the 3e minimum) in the same scenario as per your screenshot.

    Thread Starter cigno76

    (@cigno76)

    Dear Vetsos,
    I confirm that it now works perfectly!

    thank you very much
    Nicola

    Plugin Author FullStack-ing

    (@fullstackhouse)

    Hi Nicola, happy to be of a help!

    Send some of your fine tasting oil when you can! ??

    Best Regards

    Thread Starter cigno76

    (@cigno76)

    ?? ah ah! Thanks again!

    Best Regards
    Nicola

Viewing 8 replies - 16 through 23 (of 23 total)
  • The topic ‘minimum amount’ is closed to new replies.