0

I'm creating a new payment gateway plugin for wordpress and for it I need notify_url like paypal which I added and its working fine but when I'm sending data to that callback url and printing $_POST it will var dump blank array

I'm using post request from postman now and sending parameters in application/json

Example code :

public function check_response() {
        var_dump($_POST); die;
        if ( ! empty( $_POST ) ) {
            $posted = wp_unslash( $_POST );
            $order = wc_get_order( $posted['order_id'] );
            $order->update_status( $posted['status'] );
            exit;
        }
    }
Mohit Bumb
  • 2,466
  • 5
  • 33
  • 52

0 Answers0