• hewijess

    (@hewijess)


    I can not get paypal to work. I have been trying it in the sandbox and have disabled all plugins. I am using iPage.com hosting. Anyone able to give me tips on how to get it to submit correctly?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hey @hewijess

    We appreciate the very kind 5-star review.

    Unfortunately, we will require more information to rectify this concern, can you please detail the current workflow and what exactly is not working.

    Are you receiving an error after the payment has been processed?

    Our support team developed a code snippet that may potentially help, you can integrate this in a mu-plugin (must-use)* :

    add_filter(
    	'http_request_args',
    	function( $parsed_args, $url ) {
    		if ( strpos( $url, 'paypal.com/v2/checkout' ) && isset( $parsed_args[ 'body' ] ) && is_array( $parsed_args[ 'body' ] ) && empty( $parsed_args[ 'body' ] ) ) {
    			$parsed_args[ 'body' ] = '';
    		}
    		return $parsed_args;
    	},
    	10,
    	2
    );

    You can save the code as a simple text file with a .php extension and upload the file to the “/wp-content/mu-plugins” folder of your site; if there’s no “mu-plugins” folder right in the “wp-content” folder, just create it.

    We look forward to hearing from you,

    Kindly,
    Ryan

    Thread Starter hewijess

    (@hewijess)

    Thank you for the reply.

    I have added the code snippet to a php file in the “/wp-content/mu-plugins” folder. I tried to submit the form again and got a different message this time.

    This is the process I go through to create the error. I have the form set to paypal sandbox.

    I fill out the form and hit the pay with paypal button at the bottom of the form.
    A paypal window opens and I log in with my sandbox personal account.
    I click Pay Now at the bottom leaving the default Pay with balance option.
    I get a Processing animation, then window disappears and takes me back to the form.
    The top of the form shows: “Submitting…” and then gives me the error “Something went wrong.”

    Is there something else I can try to get this to work?

    Thread Starter hewijess

    (@hewijess)

    Update: I have gotten the form to successfully submit, but it doesn’t work every time. I have not figured out exactly what is causing it to fail, but if I don’t change details in the form (for example the name field) it seems to fail. Could this be true? or is it just randomly failing?

    Same issues here: https://www.lupidelsud.it/prova-iscrizione/

    It is a test form with a text and a paypal button, more simple is impossible….
    “something went wrong” error

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Payment failed, please try again!’ is closed to new replies.