• Resolved yousuft

    (@yousuft)


    Hi,

    The plugin’s nice but I have some challenges that I’m hoping you have solutions for:

    Recipient Email Sent on Wrong Order Status

    According to your docs, recipients receive gift codes via email once order status is set to Completed. I want this default behavior, but the email is being sent while the order is in Processing status. This means the gift code is valid but I haven’t verified payment yet. Checked the settings but nothing there. So how I can enable emails to only be sent on Completed status (default)?

    2. Recipient Email doesn’t render button

    Also on the email, I’ve enabled the “click here to apply code’ to render as a button in the email. The setting is enabled but a button doesn’t render in the email. How can I fix this please?

    3. Move gift code input on checkout

    I want to change the position of the gift code input form on the checkout page to above the Order Summary. Found a php snippet in this forum but it doesn’t work. Please can you help me with one? Or better yet, is there a shortcode I could use?

    Thanks a lot for your help.

    • This topic was modified 1 month, 1 week ago by yousuft.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Juan Coronel

    (@juaancmendez)

    Hello there,
    thanks for contacting us!

    1) To achieve what you need, please add the following code in the functions.php file of your active theme:

    if ( ! function_exists( 'yith_ywgc_generate_gift_card_on_order_status_custom' ) ) {
    function yith_ywgc_generate_gift_card_on_order_status_custom( $status_array ) {
    $status_array = array( 'completed' );
    return $status_array;
    }
    add_filter( 'yith_ywgc_generate_gift_card_on_order_status', 'yith_ywgc_generate_gift_card_on_order_status_custom', 10, 1 );
    }

    2) That works fine on my site. I recommend testing the plugin with everything disabled and a default WordPress theme to verify that there are no conflicts with any of them.

    3) In order to help you, I need to see the HTML of your site. Can you share the URL with me please?

    Let us know any news.

    Best regards.

    Thread Starter yousuft

    (@yousuft)

    Thanks Juan,

    1. Sorted out with the order status
    2. I’ll debug that button
    3. Don’t worry, I used the ywgc_gift_card_code_form_checkout_hook filter to move it

    Thanks for your help.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.