• Resolved i1100a

    (@i1100a)


    I’m getting the following warning on this file: woo-payment-gateway/templates/applepay-button.php

    Undefined variable: style

    Lines 7-8, to be more exact:

    <button class="apple-pay-button <?php echo $button ?>"
            style="<?php echo '-apple-pay-button-style: ' . $style . '; -apple-pay-button-type:' . apply_filters( 'wc_braintree_applepay_button_type', $type ) ?>"></button>

    Any ideas on how can this be fixed?

    Thank you!

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Payment Plugins

    (@mrclayton)

    Hi @i1100a

    Are you using a custom template for the button or the default Braintree plugin template?

    What plugin version are you running?

    Kind regards

    Thread Starter i1100a

    (@i1100a)

    Hi @mrclayton

    Thanks for the quick reply.

    I’m using v3.2.26 of the plugin. About the template, I’m using the default settings. I’m still developing the website so although I have enabled the Apple Pay gateway I haven’t had the chance to do the actual integration with Apple yet…

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @i1100a,

    I am not able to replicate this warning. The $style variable is correctly being imported into the template as expected.

    What customizations have you done to your site?

    Kind Regards,

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @i1100a,

    Any update?

    Kind Regards,

    Plugin Author Payment Plugins

    (@mrclayton)

    I did some more testing and found this notice is re-producible on the product and cart pages if Apple Pay is enabled. I’ll be including a fix for that in the next release.

    Thread Starter i1100a

    (@i1100a)

    Sorry @mrclayton I’ve been swamped!

    I’m glad you could reproduce it. Thanks for your time and effort. Great support!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Undefined variable: style’ is closed to new replies.