| 1 |
<?php |
| 2 |
|
| 3 |
$text = wppb_toolbox_get_settings( 'fields', 'send-credentials-text' ); |
| 4 |
|
| 5 |
if ( !empty( $text ) ) |
| 6 |
add_filter( 'wppb_send_credentials_checkbox_logic', 'wppb_toolbox_send_credentials_checkbox_text', 10, 2 ); |
| 7 |
|
| 8 |
function wppb_toolbox_send_credentials_checkbox_text($requestdata, $form) { |
| 9 |
$text = wppb_toolbox_get_settings( 'fields', 'send-credentials-text' ); |
| 10 |
|
| 11 |
return '<li class="wppb-form-field wppb-send-credentials-checkbox"><label for="send_credentials_via_email"><input id="send_credentials_via_email" type="checkbox" name="send_credentials_via_email" value="sending"'.( ( isset( $request_data['send_credentials_via_email'] ) && ( $request_data['send_credentials_via_email'] == 'sending' ) ) ? ' checked' : '' ).'/>'. |
| 12 |
esc_html( $text ).'</label></li>'; |
| 13 |
} |
| 14 |
|