From 83924642d91fe5dc0962cb5a5afd8442c0a0d774 Mon Sep 17 00:00:00 2001 From: "SEODEV.ORG" <115782055+seodev-org@users.noreply.github.com> Date: Tue, 29 Oct 2024 23:33:54 +0100 Subject: [PATCH 1/2] Update class-wc-postfinancecheckout-gateway.php --- .../class-wc-postfinancecheckout-gateway.php | 60 ++++++++++--------- 1 file changed, 31 insertions(+), 29 deletions(-) diff --git a/includes/class-wc-postfinancecheckout-gateway.php b/includes/class-wc-postfinancecheckout-gateway.php index 5dc2861..0813568 100644 --- a/includes/class-wc-postfinancecheckout-gateway.php +++ b/includes/class-wc-postfinancecheckout-gateway.php @@ -273,42 +273,44 @@ public function init_form_fields() { public function generate_info_html( $key, $data ) { $field_key = $this->get_field_key( $key ); $defaults = array( - 'title' => '', - 'class' => '', - 'css' => '', - 'placeholder' => '', - 'desc_tip' => true, - 'description' => '', + 'title' => '', + 'class' => '', + 'css' => '', + 'placeholder' => '', + 'desc_tip' => true, + 'description' => '', 'custom_attributes' => array(), ); - + $data = wp_parse_args( $data, $defaults ); - + ob_start(); ?> - - - - get_tooltip_html( $data ) ); ?> - - - -
- - - -
get_custom_attribute_html( $data ) ); ?> > - -
-
- - + + + get_tooltip_html( $data ); // Output the tooltip HTML directly ?> + + + +
+ + + +
get_custom_attribute_html( $data ); // Output custom attributes ?> + > + +
+
+ + Date: Tue, 29 Oct 2024 23:36:27 +0100 Subject: [PATCH 2/2] Update class-wc-postfinancecheckout-admin.php --- .../class-wc-postfinancecheckout-admin.php | 61 +++++++++---------- 1 file changed, 30 insertions(+), 31 deletions(-) diff --git a/includes/admin/class-wc-postfinancecheckout-admin.php b/includes/admin/class-wc-postfinancecheckout-admin.php index 036b769..d81346c 100644 --- a/includes/admin/class-wc-postfinancecheckout-admin.php +++ b/includes/admin/class-wc-postfinancecheckout-admin.php @@ -352,51 +352,50 @@ public function store_attribute_options( $product, $data_storage ) { //phpcs:ign * Display attribute options edit screen */ public function display_attribute_options_edit() { - if ( ! isset( $_GET['edit'] ) ) {// phpcs:ignore + if ( ! isset( $_GET['edit'] ) ) { return; } else { - $edit = esc_url_raw( wp_unslash( $_GET['edit'] ) );// phpcs:ignore + $edit = absint( $_GET['edit'] ); } - $edit = absint( $edit ); $checked = false; $attribute_options = WC_PostFinanceCheckout_Entity_Attribute_Options::load_by_attribute_id( $edit ); if ( $attribute_options->get_id() > 0 && $attribute_options->get_send() ) { $checked = true; } - echo esc_html( - ' - - - - - -

' - ) . esc_html__( 'Should this product attribute be sent to PostFinance Checkout as line item attribute?', 'woo-postfinancecheckout' ) . esc_html( - '

- - ' - ); + ?> + + + + + + /> +

+ +

+ + + - -

' - ) . esc_html__( 'Should this product attribute be sent to PostFinance Checkout as line item attribute?', 'woo-postfinancecheckout' ) . - esc_html( - '

- ' - ); + ?> +
+ +

+ +

+
+