PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
formidable / stripe / views / action-settings / gateway-buttons.php

gateway-buttons.php in Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More trunk, at stripe/views/action-settings/gateway-buttons.php

47 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if ( ! defined( 'ABSPATH' ) ) {
3 die( 'You are not allowed to call this page directly.' );
4 }
5 ?>
6 <div class="frm-long-icon-buttons" role="tablist">
7 <?php
8 foreach ( $gateways as $gateway_name => $gateway ) {
9 $is_active = in_array( $gateway_name, (array) $form_action->post_content['gateway'], true );
10 $name = $gateway['label'] ?? ucfirst( $gateway_name );
11 $gateway_classes = $gateway['recurring'] ? '' : 'frm_gateway_no_recur';
12
13 if ( $form_action->post_content['type'] === 'recurring' && ! $gateway['recurring'] ) {
14 $gateway_classes .= ' frm_hidden';
15 }
16
17 $toggle_id = "frm_toggle_{$gateway_name}_settings";
18
19 $input_params = array(
20 'id' => $toggle_id,
21 'type' => 'radio',
22 'name' => $action_control->get_field_name( 'gateway' ),
23 'value' => $gateway_name,
24 );
25
26 if ( $is_active ) {
27 $input_params['checked'] = 'checked';
28 }
29
30 $label_params = array(
31 'for' => $toggle_id,
32 'class' => trim( 'frm_payment_settings_tab frm_gateway_opt ' . $gateway_classes ),
33 'tabindex' => '0',
34 'role' => 'tab',
35 'aria-selected' => $is_active ? 'true' : 'false',
36 );
37 ?>
38 <input <?php FrmAppHelper::array_to_html_params( $input_params, true ); ?> />
39 <label <?php FrmAppHelper::array_to_html_params( $label_params, true ); ?>>
40 <?php FrmAppHelper::icon_by_class( 'frmfont frm_' . $gateway_name . '_full_icon' ); ?>
41 <span class="screen-reader-text"><?php echo esc_html( $name ); ?></span>
42 </label>
43 <?php
44 }//end foreach
45 ?>
46 </div>
47