Results 1 to 10 of 15

Hybrid View

  1. #1
    Join Date
    Aug 2011
    Posts
    8
    Plugin Contributions
    0

    Default Payment module stuck at checkout_process & before_process function?

    Hey Guys -

    Big issue here, fairly frustrating. Currently my checkout IS being processed by my gateway/payment module (aka the money is being transferred) but ZenCart stalls (blank page) at a checkout_process page that looks something like:

    main_page=checkout_process

    With a bunch of stuff after it. I've put in some echo's to try and track how far the code is firing within checkout_process.php and when a customer is successfully logged in, it gets all the way to:

    // load the before_process function from the payment modules
    $payment_modules->before_process();

    At this point it does not fire anything else, and a blank page is presented to the user.

    Is this a syntax error? Or is this an error with the module I've received from my payment gateway?

    Really appreciate the help, been trying to reference other threads for a while on this now...

    Thanks,

    -kyle

  2. #2
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: Payment module stuck at checkout_process & before_process function?

    What's the payment module? Looks like it's designed for much older versions of Zen Cart, and is passing unacceptable parameters, or parameters with very long values, both of which will cause a blank page when before_process() is run.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Aug 2011
    Posts
    8
    Plugin Contributions
    0

    Default Re: Payment module stuck at checkout_process & before_process function?

    Thanks a ton for the prompt response, really encouraging to see some support on here.

    I'm fairly certain you're correct. My clients gateway is EVO Canada, and they've supplied me with a credit card payment module that is supposed to be compatible with Zen, but it's entirely possible that it is only compatible with a much older version. It seems to be sending error messages via URL and other old-style things like that.

    Are we going to need to migrate to a different provider? Unfortunately I doubt I have the time nor experience to modify their payment module to work with the updated Zen - is a different provider our only option?

    Thanks!

  4. #4
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: Payment module stuck at checkout_process & before_process function?

    Post the code from the before_process() function of the module, and we'll see what we can do with it.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Aug 2011
    Posts
    8
    Plugin Contributions
    0

    Default Re: Payment module stuck at checkout_process & before_process function?

    Here she is:

    function before_process() {

    if ($_GET['response'] == '1') return;
    if ($_GET['response'] == '2') {
    zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_GATEWAY_SERVICES_CC_TEXT_DECLINED_MESSAGE), 'SSL', true, false));
    }
    // Code 3 is an error - but anything else is an error too (IMHO)
    zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_GATEWAY_SERVICES_CC_TEXT_ERROR_MESSAGE), 'SSL', true, false));
    }

    Any help/direction is appreciated.

  6. #6
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: Payment module stuck at checkout_process & before_process function?

    Wow, that's *extremely* basic.

    You will need to rewrite both of those zen_redirect segments so that the error_message is passed via the messageStack instead of in the zen_href_link. And you'll want to skip the urlencoding.
    An example of the changes you need to make is here: http://www.zen-cart.com/forum/showth...33#post1054133

    Or just make sure the language definitions for both of those MODULE_PAYMENT_xxxxxxxx_MESSAGE constants are less than 40 characters each.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. v154 using the payment module function get_error
    By torvista in forum Addon Payment Modules
    Replies: 5
    Last Post: 7 Nov 2024, 09:46 PM
  2. v154 BrainTree Payment Module before_process - DP-5 Errors
    By RJR in forum Addon Payment Modules
    Replies: 1
    Last Post: 7 Jan 2016, 10:15 PM
  3. v139h blank checkout_process page when using moneris payment module 1.24 or 1.25
    By riomaha in forum Addon Payment Modules
    Replies: 9
    Last Post: 1 Nov 2013, 10:45 PM
  4. Replies: 1
    Last Post: 26 Jun 2012, 01:09 AM
  5. Understanding checkout flow regarding paypal, checkout_process.php and before_process
    By s_p_ike in forum Built-in Shipping and Payment Modules
    Replies: 1
    Last Post: 1 Sep 2009, 12:50 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg