Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter btbau

    (@btbau)

    Is Afterpay working on implementing an update that will allow products to be filtered out by stock level, changes to PHP that need to be repaired after update is really kind of average.

    Thread Starter btbau

    (@btbau)

    Where do I put that code snippet?

    I have Afterpay enabled on Individual product pages and the checkout, does that code snippet get added to those respective code boxes in the plugin?

    So in the snippet box for Individual products it would look like this?

    data-show-upper-limit="true" data-show-lower-limit="true" data-logo-type="badge" data-badge-theme="black-on-mint" data-size="md" data-modal-theme="mint"
    
    function afterpay_ips_callback( $bool_result, $product ) {
         if ($product->backorders_allowed()) {
             $bool_result = false;
         }
         return $bool_result;
     }
     add_filter( 'afterpay_is_product_supported', 'afterpay_ips_callback', 10, 2 );
    • This reply was modified 2 years, 7 months ago by btbau.
Viewing 2 replies - 1 through 2 (of 2 total)