• dafcav

    (@dafcav)


    there’s an issue in this line:
    add_action( 'woocommerce_thankyou_phone_order', array( $this, 'thankyou_page' ) );

    should be:
    add_action( 'woocommerce_thankyou_' . $this->id, array( $this, 'thankyou_page' ) );

    This mod fix the instructions issue….

    I think this plugin need to add instructions on the email text also so after this add_action line should add:
    add_action( 'woocommerce_email_before_order_table', array( $this, 'email_instructions' ), 10, 3 );

    and after thankyou_page function should add:

    public function email_instructions( $order, $sent_to_admin, $plain_text = false ) {
    		    if ( $this->instructions && ! $sent_to_admin && 'woocommerce_phone_order' === $order->payment_method ) {
    			echo wpautop( wptexturize( $this->instructions ) ) . PHP_EOL;
    		    }
    		}

    https://www.ads-software.com/plugins/woocommerce-phone-order-gateway/

Viewing 1 replies (of 1 total)
  • Plugin Author Yonatan Ganot

    (@xxxyonixxx)

    Hey,

    I’ve changed and added this code in v1.1.

    Thanks for your help!

Viewing 1 replies (of 1 total)
  • The topic ‘Instructions are not been displayed on thankyou page’ is closed to new replies.