@@ -7,26 +7,26 @@ discard block |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | // Make sure that the form is active. |
13 | -if ( ! $form->is_active() ) { |
|
13 | +if (!$form->is_active()) { |
|
14 | 14 | echo aui()->alert( |
15 | 15 | array( |
16 | 16 | 'type' => 'warning', |
17 | - 'content' => __( 'This payment form is no longer active', 'invoicing' ), |
|
17 | + 'content' => __('This payment form is no longer active', 'invoicing'), |
|
18 | 18 | ) |
19 | 19 | ); |
20 | 20 | return; |
21 | 21 | } |
22 | 22 | |
23 | 23 | // Require login to checkout. |
24 | -if ( wpinv_require_login_to_checkout() && ! get_current_user_id() ) { |
|
24 | +if (wpinv_require_login_to_checkout() && !get_current_user_id()) { |
|
25 | 25 | |
26 | 26 | echo aui()->alert( |
27 | 27 | array( |
28 | 28 | 'type' => 'danger', |
29 | - 'content' => __( 'You must be logged in to checkout.', 'invoicing' ), |
|
29 | + 'content' => __('You must be logged in to checkout.', 'invoicing'), |
|
30 | 30 | ) |
31 | 31 | ); |
32 | 32 | return; |
@@ -34,29 +34,29 @@ discard block |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | // Fires before displaying a payment form. |
37 | -do_action( 'getpaid_before_payment_form', $form ); |
|
37 | +do_action('getpaid_before_payment_form', $form); |
|
38 | 38 | ?> |
39 | 39 | |
40 | -<form class='getpaid-payment-form getpaid-payment-form-<?php echo absint( $form->get_id() ); ?> bsui position-relative' method='POST' data-key='<?php echo uniqid( 'gpf' ); ?>' data-currency='<?php echo esc_attr( empty( $form->invoice ) ? wpinv_get_currency() : $form->invoice->get_currency() ); ?>' novalidate> |
|
40 | +<form class='getpaid-payment-form getpaid-payment-form-<?php echo absint($form->get_id()); ?> bsui position-relative' method='POST' data-key='<?php echo uniqid('gpf'); ?>' data-currency='<?php echo esc_attr(empty($form->invoice) ? wpinv_get_currency() : $form->invoice->get_currency()); ?>' novalidate> |
|
41 | 41 | |
42 | 42 | <?php |
43 | 43 | |
44 | 44 | // Fires when printing the top of a payment form. |
45 | - do_action( 'getpaid_payment_form_top', $form ); |
|
45 | + do_action('getpaid_payment_form_top', $form); |
|
46 | 46 | |
47 | 47 | // And the optional invoice id. |
48 | - if ( ! empty( $form->invoice ) ) { |
|
49 | - echo getpaid_hidden_field( 'invoice_id', $form->invoice->get_id() ); |
|
48 | + if (!empty($form->invoice)) { |
|
49 | + echo getpaid_hidden_field('invoice_id', $form->invoice->get_id()); |
|
50 | 50 | } |
51 | 51 | |
52 | 52 | // We also want to include the form id. |
53 | - echo getpaid_hidden_field( 'form_id', $form->get_id() ); |
|
53 | + echo getpaid_hidden_field('form_id', $form->get_id()); |
|
54 | 54 | |
55 | 55 | // And an indication that this is a payment form submission. |
56 | - echo getpaid_hidden_field( 'getpaid_payment_form_submission', '1' ); |
|
56 | + echo getpaid_hidden_field('getpaid_payment_form_submission', '1'); |
|
57 | 57 | |
58 | 58 | // Fires before displaying payment form elements. |
59 | - do_action( 'getpaid_payment_form_before_elements', $form ); |
|
59 | + do_action('getpaid_payment_form_before_elements', $form); |
|
60 | 60 | |
61 | 61 | // Display the elements. |
62 | 62 | ?> |
@@ -64,13 +64,13 @@ discard block |
||
64 | 64 | <div class="row"> |
65 | 65 | <?php |
66 | 66 | |
67 | - foreach ( $form->get_elements() as $element ) { |
|
67 | + foreach ($form->get_elements() as $element) { |
|
68 | 68 | |
69 | - if ( isset( $element['type'] ) ) { |
|
70 | - $grid_class = esc_attr( getpaid_get_form_element_grid_class( $element ) ); |
|
69 | + if (isset($element['type'])) { |
|
70 | + $grid_class = esc_attr(getpaid_get_form_element_grid_class($element)); |
|
71 | 71 | echo "<div class='$grid_class'>"; |
72 | - do_action( 'getpaid_payment_form_element', $element, $form ); |
|
73 | - do_action( "getpaid_payment_form_element_{$element['type']}_template", $element, $form ); |
|
72 | + do_action('getpaid_payment_form_element', $element, $form); |
|
73 | + do_action("getpaid_payment_form_element_{$element['type']}_template", $element, $form); |
|
74 | 74 | echo '</div>'; |
75 | 75 | } |
76 | 76 | } |
@@ -81,28 +81,28 @@ discard block |
||
81 | 81 | |
82 | 82 | <?php |
83 | 83 | // Fires after displaying payment form elements. |
84 | - do_action( 'getpaid_payment_form_after_elements', $form ); |
|
84 | + do_action('getpaid_payment_form_after_elements', $form); |
|
85 | 85 | |
86 | 86 | echo "<div class='getpaid-payment-form-errors alert alert-danger d-none'></div>"; |
87 | 87 | |
88 | - if ( wpinv_current_user_can_manage_invoicing() ) { |
|
88 | + if (wpinv_current_user_can_manage_invoicing()) { |
|
89 | 89 | |
90 | 90 | edit_post_link( |
91 | - __( 'Edit this form.', 'invoicing' ), |
|
91 | + __('Edit this form.', 'invoicing'), |
|
92 | 92 | '<small class="form-text text-muted">', |
93 | - ' ' . __( 'This is only visible to website administators.', 'invoicing' ) . '</small>', |
|
93 | + ' ' . __('This is only visible to website administators.', 'invoicing') . '</small>', |
|
94 | 94 | $form->get_id(), |
95 | 95 | 'text-danger' |
96 | 96 | ); |
97 | 97 | |
98 | 98 | } |
99 | 99 | |
100 | - echo wp_kses_post( $extra_markup ); |
|
100 | + echo wp_kses_post($extra_markup); |
|
101 | 101 | ?> |
102 | 102 | |
103 | 103 | <div class="loading_div overlay overlay-black position-absolute row m-0 rounded overflow-hidden" style="height: 100%;width: 100%;top: 0px;z-index: 2;display:none;"> |
104 | 104 | <div class="spinner-border mx-auto align-self-center text-white" role="status"> |
105 | - <span class="sr-only"><?php esc_html_e( 'Loading...', 'invoicing' ); ?></span> |
|
105 | + <span class="sr-only"><?php esc_html_e('Loading...', 'invoicing'); ?></span> |
|
106 | 106 | </div> |
107 | 107 | </div> |
108 | 108 | |
@@ -111,4 +111,4 @@ discard block |
||
111 | 111 | <?php |
112 | 112 | |
113 | 113 | // Fires after displaying a payment form. |
114 | -do_action( 'getpaid_after_payment_form', $form ); |
|
114 | +do_action('getpaid_after_payment_form', $form); |
@@ -7,33 +7,33 @@ discard block |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
11 | - |
|
12 | -$label = empty( $label ) ? '' : wp_kses_post( $label ); |
|
13 | -$label_class = sanitize_key( preg_replace( '/[^A-Za-z0-9_-]/', '-', $label ) ); |
|
14 | -$id = esc_attr( $id ); |
|
15 | -$_id = $id . uniqid( '_' ); |
|
16 | -$max_file_num = empty( $max_file_num ) ? 1 : absint( $max_file_num ); |
|
17 | -$file_types = empty( $file_types ) ? array( 'jpg|jpeg|jpe', 'gif', 'png' ) : $file_types; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | + |
|
12 | +$label = empty($label) ? '' : wp_kses_post($label); |
|
13 | +$label_class = sanitize_key(preg_replace('/[^A-Za-z0-9_-]/', '-', $label)); |
|
14 | +$id = esc_attr($id); |
|
15 | +$_id = $id . uniqid('_'); |
|
16 | +$max_file_num = empty($max_file_num) ? 1 : absint($max_file_num); |
|
17 | +$file_types = empty($file_types) ? array('jpg|jpeg|jpe', 'gif', 'png') : $file_types; |
|
18 | 18 | $all_types = getpaid_get_allowed_mime_types(); |
19 | 19 | $types = array(); |
20 | 20 | $_types = array(); |
21 | 21 | |
22 | -foreach ( $file_types as $file_type ) { |
|
22 | +foreach ($file_types as $file_type) { |
|
23 | 23 | |
24 | - if ( isset( $all_types[ $file_type ] ) ) { |
|
25 | - $types[] = $all_types[ $file_type ]; |
|
26 | - $file_type = explode( '|', $file_type ); |
|
24 | + if (isset($all_types[$file_type])) { |
|
25 | + $types[] = $all_types[$file_type]; |
|
26 | + $file_type = explode('|', $file_type); |
|
27 | 27 | |
28 | - foreach ( $file_type as $type ) { |
|
29 | - $type = trim( $type ); |
|
28 | + foreach ($file_type as $type) { |
|
29 | + $type = trim($type); |
|
30 | 30 | $types[] = ".$type"; |
31 | 31 | $_types[] = $type; |
32 | 32 | } |
33 | 33 | } |
34 | 34 | } |
35 | 35 | |
36 | -if ( ! empty( $required ) ) { |
|
36 | +if (!empty($required)) { |
|
37 | 37 | $label .= "<span class='text-danger'> *</span>"; |
38 | 38 | } |
39 | 39 | |
@@ -41,16 +41,16 @@ discard block |
||
41 | 41 | |
42 | 42 | <label><span v-html="form_element.label"></span></label> |
43 | 43 | |
44 | -<div class="form-group <?php echo sanitize_html_class( $label_class ); ?>" data-name="<?php echo esc_attr( $id ); ?>" data-max="<?php echo esc_attr( $max_file_num ); ?>"> |
|
45 | - <label for="<?php echo esc_attr( $id ); ?>"><?php echo wp_kses_post( $label ); ?></label> |
|
46 | - <input type="file" class="sr-only getpaid-files-input" id="<?php echo esc_attr( $id ); ?>" accept="<?php echo esc_attr( implode( ', ', $types ) ); ?>" data-extensions="<?php echo esc_attr( wp_json_encode( $_types ) ); ?>" <?php echo $max_file_num == 1 ? '' : 'multiple="multiple"'; ?>> |
|
44 | +<div class="form-group <?php echo sanitize_html_class($label_class); ?>" data-name="<?php echo esc_attr($id); ?>" data-max="<?php echo esc_attr($max_file_num); ?>"> |
|
45 | + <label for="<?php echo esc_attr($id); ?>"><?php echo wp_kses_post($label); ?></label> |
|
46 | + <input type="file" class="sr-only getpaid-files-input" id="<?php echo esc_attr($id); ?>" accept="<?php echo esc_attr(implode(', ', $types)); ?>" data-extensions="<?php echo esc_attr(wp_json_encode($_types)); ?>" <?php echo $max_file_num == 1 ? '' : 'multiple="multiple"'; ?>> |
|
47 | 47 | |
48 | - <label for="<?php echo esc_attr( $id ); ?>" class="getpaid-file-upload-element d-flex w-100 flex-column align-items-center justify-content-center p-2 mb-2"> |
|
48 | + <label for="<?php echo esc_attr($id); ?>" class="getpaid-file-upload-element d-flex w-100 flex-column align-items-center justify-content-center p-2 mb-2"> |
|
49 | 49 | <div class="h5 text-dark"> |
50 | - <?php echo _n( 'Drag your file to this area or click to upload', 'Drag files to this area or click to upload', $max_file_num, 'invoicing' ); ?> |
|
50 | + <?php echo _n('Drag your file to this area or click to upload', 'Drag files to this area or click to upload', $max_file_num, 'invoicing'); ?> |
|
51 | 51 | </div> |
52 | - <?php if ( ! empty( $description ) ) : ?> |
|
53 | - <small class="form-text text-muted"><?php echo wp_kses_post( $description ); ?></small> |
|
52 | + <?php if (!empty($description)) : ?> |
|
53 | + <small class="form-text text-muted"><?php echo wp_kses_post($description); ?></small> |
|
54 | 54 | <?php endif; ?> |
55 | 55 | </label> |
56 | 56 | |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | <div class="form-row mb-3 d-none getpaid-progress-template"> |
60 | 60 | |
61 | 61 | <div class="overflow-hidden text-nowrap col-7 col-sm-4"> |
62 | - <a href="" class="close float-none" title="<?php esc_attr_e( 'Remove File', 'invoicing' ); ?>">×<span class="sr-only"><?php esc_html_e( 'Close', 'invoicing' ); ?></span></a> |
|
62 | + <a href="" class="close float-none" title="<?php esc_attr_e('Remove File', 'invoicing'); ?>">×<span class="sr-only"><?php esc_html_e('Close', 'invoicing'); ?></span></a> |
|
63 | 63 | <i class="fa fa-file" aria-hidden="true"></i> <span class="getpaid-progress-file-name"></span> |
64 | 64 | </div> |
65 | 65 |
@@ -7,24 +7,24 @@ |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | -$label = empty( $label ) ? '' : wp_kses_post( $label ); |
|
13 | -$label_class = sanitize_key( preg_replace( '/[^A-Za-z0-9_-]/', '-', $label ) ); |
|
12 | +$label = empty($label) ? '' : wp_kses_post($label); |
|
13 | +$label_class = sanitize_key(preg_replace('/[^A-Za-z0-9_-]/', '-', $label)); |
|
14 | 14 | |
15 | -if ( ! empty( $required ) ) { |
|
15 | +if (!empty($required)) { |
|
16 | 16 | $label .= "<span class='text-danger'> *</span>"; |
17 | 17 | } |
18 | 18 | |
19 | 19 | echo aui()->input( |
20 | 20 | array( |
21 | - 'name' => esc_attr( $id ), |
|
22 | - 'id' => esc_attr( $id . uniqid( '_' ) ), |
|
23 | - 'placeholder' => empty( $placeholder ) ? '' : esc_attr( $placeholder ), |
|
24 | - 'required' => ! empty( $required ), |
|
21 | + 'name' => esc_attr($id), |
|
22 | + 'id' => esc_attr($id . uniqid('_')), |
|
23 | + 'placeholder' => empty($placeholder) ? '' : esc_attr($placeholder), |
|
24 | + 'required' => !empty($required), |
|
25 | 25 | 'label' => $label, |
26 | 26 | 'label_type' => 'vertical', |
27 | - 'help_text' => empty( $description ) ? '' : wp_kses_post( $description ), |
|
28 | - 'class' => esc_attr( $label_class ), |
|
27 | + 'help_text' => empty($description) ? '' : wp_kses_post($description), |
|
28 | + 'class' => esc_attr($label_class), |
|
29 | 29 | ) |
30 | 30 | ); |
@@ -8,20 +8,20 @@ discard block |
||
8 | 8 | * @var GetPaid_Payment_Form $form The current payment form |
9 | 9 | */ |
10 | 10 | |
11 | -defined( 'ABSPATH' ) || exit; |
|
11 | +defined('ABSPATH') || exit; |
|
12 | 12 | |
13 | -if ( ! getpaid_has_published_discount() ) { |
|
13 | +if (!getpaid_has_published_discount()) { |
|
14 | 14 | return; |
15 | 15 | } |
16 | 16 | |
17 | -if ( ! empty( $description ) ) { |
|
17 | +if (!empty($description)) { |
|
18 | 18 | $description = "<small class='form-text text-muted'>$description</small>"; |
19 | 19 | } else { |
20 | 20 | $description = ''; |
21 | 21 | } |
22 | 22 | |
23 | 23 | $discount_code = ''; |
24 | -if ( ! empty( $form->invoice ) ) { |
|
24 | +if (!empty($form->invoice)) { |
|
25 | 25 | $discount_code = $form->invoice->get_discount_code(); |
26 | 26 | } |
27 | 27 | |
@@ -30,12 +30,12 @@ discard block |
||
30 | 30 | <div class="form-group"> |
31 | 31 | <div class="getpaid-discount-field border rounded p-3"> |
32 | 32 | <div class="getpaid-discount-field-inner d-flex flex-column flex-md-row"> |
33 | - <input name="discount" placeholder="<?php echo esc_attr( $input_label ); ?>" value="<?php echo esc_attr( $discount_code ); ?>" class="form-control mr-2 mb-2 getpaid-discount-field-input" style="flex: 1;" type="text"> |
|
34 | - <a href="#" class="btn btn-secondary submit-button mb-2 getpaid-discount-button"><?php echo esc_html( $button_label ); ?></a> |
|
33 | + <input name="discount" placeholder="<?php echo esc_attr($input_label); ?>" value="<?php echo esc_attr($discount_code); ?>" class="form-control mr-2 mb-2 getpaid-discount-field-input" style="flex: 1;" type="text"> |
|
34 | + <a href="#" class="btn btn-secondary submit-button mb-2 getpaid-discount-button"><?php echo esc_html($button_label); ?></a> |
|
35 | 35 | </div> |
36 | - <?php echo wp_kses_post( $description ); ?> |
|
36 | + <?php echo wp_kses_post($description); ?> |
|
37 | 37 | <div class="getpaid-custom-payment-form-errors alert alert-danger d-none"></div> |
38 | - <div class="getpaid-custom-payment-form-success alert alert-success d-none"><?php esc_html_e( 'Discount code applied!', 'invoicing' ); ?></div> |
|
38 | + <div class="getpaid-custom-payment-form-success alert alert-success d-none"><?php esc_html_e('Discount code applied!', 'invoicing'); ?></div> |
|
39 | 39 | </div> |
40 | 40 | </div> |
41 | 41 |
@@ -7,57 +7,57 @@ discard block |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | -if ( empty( $fields ) ) { |
|
12 | +if (empty($fields)) { |
|
13 | 13 | return; |
14 | 14 | } |
15 | 15 | |
16 | 16 | // A prefix for all ids (so that a form can be included in the same page multiple times). |
17 | -$uniqid = uniqid( '_' ); |
|
17 | +$uniqid = uniqid('_'); |
|
18 | 18 | |
19 | 19 | // Prepare the user's country. |
20 | -if ( ! empty( $form->invoice ) ) { |
|
20 | +if (!empty($form->invoice)) { |
|
21 | 21 | $country = $form->invoice->get_country(); |
22 | 22 | } |
23 | 23 | |
24 | -if ( empty( $country ) ) { |
|
25 | - $country = empty( $country ) ? getpaid_get_ip_country() : $country; |
|
26 | - $country = empty( $country ) ? wpinv_get_default_country() : $country; |
|
24 | +if (empty($country)) { |
|
25 | + $country = empty($country) ? getpaid_get_ip_country() : $country; |
|
26 | + $country = empty($country) ? wpinv_get_default_country() : $country; |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | // A prefix for all ids (so that a form can be included in the same page multiple times). |
30 | -$uniqid = uniqid( '_' ); |
|
30 | +$uniqid = uniqid('_'); |
|
31 | 31 | |
32 | -$address_type = empty( $address_type ) ? 'billing' : $address_type; |
|
32 | +$address_type = empty($address_type) ? 'billing' : $address_type; |
|
33 | 33 | |
34 | 34 | ?> |
35 | 35 | |
36 | -<?php if ( 'both' === $address_type ) : ?> |
|
36 | +<?php if ('both' === $address_type) : ?> |
|
37 | 37 | |
38 | 38 | <!-- Start Billing/Shipping Address Title --> |
39 | 39 | <h4 class="mb-3 getpaid-shipping-billing-address-title"> |
40 | - <?php esc_html_e( 'Billing / Shipping Address', 'invoicing' ); ?> |
|
40 | + <?php esc_html_e('Billing / Shipping Address', 'invoicing'); ?> |
|
41 | 41 | </h4> |
42 | 42 | <!-- End Billing Address Title --> |
43 | 43 | |
44 | 44 | <!-- Start Billing Address Title --> |
45 | 45 | <h4 class="mb-3 getpaid-billing-address-title"> |
46 | - <?php esc_html_e( 'Billing Address', 'invoicing' ); ?> |
|
46 | + <?php esc_html_e('Billing Address', 'invoicing'); ?> |
|
47 | 47 | </h4> |
48 | 48 | <!-- End Billing Address Title --> |
49 | 49 | |
50 | 50 | <?php endif; ?> |
51 | 51 | |
52 | 52 | |
53 | -<?php if ( 'both' === $address_type || 'billing' === $address_type ) : ?> |
|
53 | +<?php if ('both' === $address_type || 'billing' === $address_type) : ?> |
|
54 | 54 | |
55 | 55 | <!-- Start Billing Address --> |
56 | 56 | <div class="getpaid-billing-address-wrapper"> |
57 | 57 | <?php |
58 | 58 | $field_type = 'billing'; |
59 | - include plugin_dir_path( __FILE__ ) . 'address-fields.php'; |
|
60 | - do_action( 'getpaid_after_payment_form_billing_fields', $form ); |
|
59 | + include plugin_dir_path(__FILE__) . 'address-fields.php'; |
|
60 | + do_action('getpaid_after_payment_form_billing_fields', $form); |
|
61 | 61 | ?> |
62 | 62 | </div> |
63 | 63 | <!-- End Billing Address --> |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | <?php endif; ?> |
66 | 66 | |
67 | 67 | |
68 | -<?php if ( 'both' === $address_type ) : ?> |
|
68 | +<?php if ('both' === $address_type) : ?> |
|
69 | 69 | |
70 | 70 | |
71 | 71 | <?php |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | 'name' => 'same-shipping-address', |
77 | 77 | 'id' => "shipping-toggle$uniqid", |
78 | 78 | 'required' => false, |
79 | - 'label' => wp_kses_post( $shipping_address_toggle ), |
|
79 | + 'label' => wp_kses_post($shipping_address_toggle), |
|
80 | 80 | 'value' => 1, |
81 | 81 | 'checked' => true, |
82 | 82 | 'class' => 'w-auto', |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | |
89 | 89 | <!-- Start Shipping Address Title --> |
90 | 90 | <h4 class="mb-3 getpaid-shipping-address-title"> |
91 | - <?php esc_html_e( 'Shipping Address', 'invoicing' ); ?> |
|
91 | + <?php esc_html_e('Shipping Address', 'invoicing'); ?> |
|
92 | 92 | </h4> |
93 | 93 | <!-- End Shipping Address Title --> |
94 | 94 | |
@@ -97,14 +97,14 @@ discard block |
||
97 | 97 | |
98 | 98 | |
99 | 99 | |
100 | -<?php if ( 'both' === $address_type || 'shipping' === $address_type ) : ?> |
|
100 | +<?php if ('both' === $address_type || 'shipping' === $address_type) : ?> |
|
101 | 101 | |
102 | 102 | <!-- Start Shipping Address --> |
103 | 103 | <div class="getpaid-shipping-address-wrapper"> |
104 | 104 | <?php |
105 | 105 | $field_type = 'shipping'; |
106 | - include plugin_dir_path( __FILE__ ) . 'address-fields.php'; |
|
107 | - do_action( 'getpaid_after_payment_form_shipping_fields', $form ); |
|
106 | + include plugin_dir_path(__FILE__) . 'address-fields.php'; |
|
107 | + do_action('getpaid_after_payment_form_shipping_fields', $form); |
|
108 | 108 | ?> |
109 | 109 | </div> |
110 | 110 | <!-- End Shipping Address --> |
@@ -3,8 +3,8 @@ discard block |
||
3 | 3 | <p> |
4 | 4 | <?php |
5 | 5 | echo wp_sprintf( |
6 | - wp_kses_post( __( 'Your payment is processing. This page will reload automatically in 10 seconds. If it does not, click <a href="%s">here</a>.', 'invoicing' ) ), |
|
7 | - esc_url_raw( remove_query_arg( 'payment-confirm' ) ) |
|
6 | + wp_kses_post(__('Your payment is processing. This page will reload automatically in 10 seconds. If it does not, click <a href="%s">here</a>.', 'invoicing')), |
|
7 | + esc_url_raw(remove_query_arg('payment-confirm')) |
|
8 | 8 | ); |
9 | 9 | ?> |
10 | 10 | <i class="fa fa-spin fa-refresh"></i> |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | <script type="text/javascript"> |
14 | 14 | setTimeout( |
15 | 15 | function(){ |
16 | - window.location.href = '<?php echo esc_url_raw( remove_query_arg( 'payment-confirm' ) ); ?>'; |
|
16 | + window.location.href = '<?php echo esc_url_raw(remove_query_arg('payment-confirm')); ?>'; |
|
17 | 17 | }, |
18 | 18 | 10000 |
19 | 19 | ); |
@@ -7,14 +7,14 @@ |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | ?> |
13 | 13 | |
14 | 14 | <div v-if='!is_default'> |
15 | - <div class='alert alert-info' role='alert'><?php esc_html_e( 'Item totals will appear here. Click to set items.', 'invoicing' ); ?></div> |
|
15 | + <div class='alert alert-info' role='alert'><?php esc_html_e('Item totals will appear here. Click to set items.', 'invoicing'); ?></div> |
|
16 | 16 | </div> |
17 | 17 | |
18 | 18 | <div v-if='is_default'> |
19 | - <div class='alert alert-info' role='alert'><?php esc_html_e( 'Item totals will appear here.', 'invoicing' ); ?></div> |
|
19 | + <div class='alert alert-info' role='alert'><?php esc_html_e('Item totals will appear here.', 'invoicing'); ?></div> |
|
20 | 20 | </div> |
@@ -7,15 +7,15 @@ |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | ?> |
13 | 13 | |
14 | 14 | <label><span v-html="form_element.label"></span></label> |
15 | 15 | <div class="d-flex w-100 flex-column align-items-center justify-content-center p-2" style="height: 200px; border: 3px dashed rgb(136, 136, 136); cursor: pointer;"> |
16 | 16 | <div class="h5 text-dark"> |
17 | - <span v-if="form_element.max_file_num > 1"><?php esc_html_e( 'Drag files to this area or click to upload', 'invoicing' ); ?></span> |
|
18 | - <span v-if="form_element.max_file_num < 2"><?php esc_html_e( 'Drag your file to this area or click to upload', 'invoicing' ); ?></span> |
|
17 | + <span v-if="form_element.max_file_num > 1"><?php esc_html_e('Drag files to this area or click to upload', 'invoicing'); ?></span> |
|
18 | + <span v-if="form_element.max_file_num < 2"><?php esc_html_e('Drag your file to this area or click to upload', 'invoicing'); ?></span> |
|
19 | 19 | </div> |
20 | 20 | <small v-if='form_element.description' class='form-text text-muted' v-html='form_element.description'></small> |
21 | 21 | </div> |
@@ -7,16 +7,16 @@ discard block |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | // Set the currency position. |
13 | 13 | $position = wpinv_currency_position(); |
14 | 14 | |
15 | -if ( $position == 'left_space' ) { |
|
15 | +if ($position == 'left_space') { |
|
16 | 16 | $position = 'left'; |
17 | 17 | } |
18 | 18 | |
19 | -if ( $position == 'right_space' ) { |
|
19 | +if ($position == 'right_space') { |
|
20 | 20 | $position = 'right'; |
21 | 21 | } |
22 | 22 | |
@@ -26,17 +26,17 @@ discard block |
||
26 | 26 | |
27 | 27 | <div class="input-group"> |
28 | 28 | |
29 | - <?php if ( $position == 'left' ) : ?> |
|
29 | + <?php if ($position == 'left') : ?> |
|
30 | 30 | <div class="input-group-prepend"> |
31 | - <span class="input-group-text"><?php echo wp_kses_post( wpinv_currency_symbol() ); ?></span> |
|
31 | + <span class="input-group-text"><?php echo wp_kses_post(wpinv_currency_symbol()); ?></span> |
|
32 | 32 | </div> |
33 | 33 | <?php endif; ?> |
34 | 34 | |
35 | 35 | <input :placeholder='form_element.placeholder' class='form-control' type='text'> |
36 | 36 | |
37 | - <?php if ( $position == 'right' ) : ?> |
|
37 | + <?php if ($position == 'right') : ?> |
|
38 | 38 | <div class="input-group-append"> |
39 | - <span class="input-group-text"><?php echo wp_kses_post( wpinv_currency_symbol() ); ?></span> |
|
39 | + <span class="input-group-text"><?php echo wp_kses_post(wpinv_currency_symbol()); ?></span> |
|
40 | 40 | </div> |
41 | 41 | <?php endif; ?> |
42 | 42 | </div> |