GP Limit Choices // Gravity Perks // Modify the "Out of Stock" Message
<?php
/**
* GP Limit Choices // Gravity Perks // Modify the "Out of Stock" Message
*/
add_filter( 'gplc_out_of_stock_message', function( $not_enough_stock_message, $form, $field, $inventory_data ) {
return 'Sorry, friends. This item is no longer avialable.';
}, 10, 4 );
// only apply to form ID 1
add_filter( 'gplc_out_of_stock_message_1', function( ) { /* custom code */ }, 10, 4 );
// only apply to field ID 2 on form ID 1
add_filter( 'gplc_out_of_stock_message_1_2', function( ) { /* custom code */ }, 10, 4 );