• Resolved georgediscoverable

    (@georgediscoverable)


    Hi,

    I have the plugin set for test mode and have the API keys and merchant ID from Worldpay in the account.

    Getting this as the message when I try to pay:

    “Error processing payment. Reason: One of Token or Payment page config must be provided”

    Any help would be appreciated!

    Thanks,
    George

    The page I need help with: [log in to see the link]

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

    (@mrclayton)

    Hi @georgediscoverable,

    I wasn’t able to test your website because there is a fatal error being triggered by an undefined function related to your twitter integration.

    Once you get that resolved I’ll take another look at your checkout page.

    Thanks,

    Thread Starter georgediscoverable

    (@georgediscoverable)

    Hi,

    I’ve removed that function now, we’re using this site as a sandbox but I wasn’t aware it was stopping the site from functioning.

    As I said, that’s removed now, you can access a test product on shop.stephen-webster.co.uk/shop/test/

    Thanks for your help so far!

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @georgediscoverable,

    Can you please respond with instructions on how to navigate your site and where the products are located? I don’t see anything on the standard shop page.

    Thanks,

    Thread Starter georgediscoverable

    (@georgediscoverable)

    Hi @mrclayton ,

    I put directions in the previous message but you can find the test product (which is/will be proof of concept for the client before building everything else) at this page .

    Thanks,
    George

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @georgediscoverable,

    On your checkout page, the required WC JS scripts are not being loaded. Notice if you click place order the page refreshes instead of making the standard ajax call to process the order.

    WC outputs the checkout scripts and all dependencies using the is_checkout function call. You can find what I am referencing in the woocommerce/includes/class-wc-frontend-scripts.php file. Our plugin works in a similar manner and its checkout page scripts are also not being loaded.

    You will first need to figure out why those scripts are not being included in the checkout page. Perhaps some of your custom development is conflicting or another plugin is causing some issues.

    Kind Regards,

    Hi @mrclayton

    I am facing the same issue, the custom form is not working and its throwing token error, following is my product page and you can check the checkout: https://mariacristinafoundation.org/MCFoundation/dev/product/test-book-1/

    Looking forward for your response!

    Kind Regards

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @khemwh,

    I was able to see the error during checkout on your site. I will try and re-create on our test site and will respond to this thread.

    Are you getting the same error if you use the iFrame form?

    Kind Regards,

    Hi @mrclayton,

    If I select iframe option then form do not render on checkout page, please check that as well!

    Thanks for your response!

    Best Regards

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @khemwh,

    I reviewed your site again and the issue is the plugin’s localized Javascript parameters are not being output to the checkout page. Our plugin uses the action wp_print_footer_scripts to output parameters that the Javascript requires.

    It appears your theme is not calling that action. There is another action that we could use, wp_print_scripts, but that will require an update to the plugin version.

    Are you able to access your plugins directory? If so we can run a test to make sure that change will solve your problem.

    Navigate to wp-content/plugins/woo-easy-pay/includes/class-worldpay-frontend-scripts.php. Locate the static method called init and replace it with the following:

    public static function init() {
    		add_action ( 'wp_enqueue_scripts', __CLASS__ . '::enqueue_scripts' );
    		add_action ( 'wp_print_scripts', __CLASS__ . '::localize_scripts', 5 );
    		//add_action ( 'wp_print_footer_scripts', __CLASS__ . '::localize_scripts', 5 );
    		
    		define ( 'WORLDPAY_JS', 'https://cdn.worldpay.com/v1/worldpay.js' );
    	}

    Test the checkout page after making this change and let me know if your issue is resolved. If so I can release an update.

    Kind Regards,

    Hi @mrclayton,

    Thanks for your efforts and help!

    All the issues related to the form rendering have been resolved using the above fix. Form is working with iframe as well.

    Please release the update for this fix.

    Best Regards

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @khemwh,

    Version 2.0.2 has been released and includes these changes.

    Thanks,

    Hi @mrclayton

    I have the latest plugin version 2.0.2 on one of my sites and am experiencing the same problem above unfortunately.

    I have WordPress version 5.2–en_GB
    WooCommerce version 3.6.2

    The iframe form is not loading from Worldpay anymore, if I use and submit the other forms I get the error message:

    “Error processing payment. Reason: One of Token or Payment page config must be provided”

    You can view the checkout here: bit.ly/2Hh3dIi

    Any help would be appreciated.

    Thanks

    Plugin Author Payment Plugins

    (@mrclayton)

    Hi @russstephens777,

    I reviewed your checkout page and the parameters are being output correctly. Your issue is related to a JavaScript error in your theme that’s affecting the iFrame form from loading.

    Using chrome, click F12 to open the browser developer tools. Click the console tab and you will see the JavaScript error.

    Kind Regards,

    Thanks for the quick response @mrclayton

    Fixed the JavaScript error, all good and working now.

    Plugin Author Payment Plugins

    (@mrclayton)

    @russstephens777 you bet, glad we could help.

    A nice review is always appreciated ??

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Error processing payment. Reason: One of Token or Payment page config must be pr’ is closed to new replies.