Order information not recording in MP

I’ve had a few (rare) issues with orders not being recorded in the database properly. We are using Paypal Chained payments and the payments are being sent properly, and the order created. However, the order information that goes into the wp_postmeta table isn’t being populated. Some of the rows are, but not the really, really, important ones like mp_shipping_info and mp_cart_info – this leaves us without that crucial information. The other rows in that table fill up and relate correctly to the entry in wp_posts

Now, what I’m wondering is when does that information get populated? Before the payment transaction in some sort of pending status, or after the payment transaction? I know our site has been getting out of memory errors and I’m wondering if that happened during the transaction process, and the info didn’t get written after the customer came back from paypal, or if there is some other issue. Some insight would be useful, this is the second its happened to this seller in two months and she’s getting pretty frustrated with me because I don’t have answers for her.

  • Paul Barthmaier
    • Code Wrangler

    Hi there SV,

    Interesting situation. I don’t really have any answers and it’s probably best to get the developer’s perspective on this. It looks like you have everything updated, including Marketpress, so I’m not sure what could be going on. Nor have I heard any others describe a situation like this. I’ve pinged him and hope he can pop in with some advice.



  • Aaron
    • CTO

    That’s interesting and kinda tricky. In the chained payments module, when a user gets sent to paypal to checkout they don’t get reliably sent back to the marketpress store. The page on paypal has a timer, then redirects after a countdown. If they user closed that window, or navigates somewhere else before that then they won’t get sent to the MP confirmation page.

    So to this gateway creates the order 2 ways. Primarily, after the redirect it will create the order on the confirmation page. If they skip that, then the order is created when the paypal IPN is received.

    To store order info untill the ipn is received, we save it in transients with a 12 hour expire:

    $cart = get_transient('mp_order_' . $order_id . '_cart');
    $shipping_info = get_transient('mp_order_' . $order_id . '_shipping');
    $shipping_total = get_transient('mp_order_' . $order_id . '_shipping_total');
    $tax_total = get_transient('mp_order_' . $order_id . '_tax_total');
    $user_id = get_transient('mp_order_' . $order_id . '_userid');
    $coupon_code = get_transient('mp_order_' . $order_id . '_coupon');

    It may be possible that some of those transients are not being lost or not stored before the IPN comes through. That sounds most likely. It’s possible for another plugin (especially caching ones) to mess up transient storage.

    So you could try disabling any object caching plugins, or checking they are properly configured. You could also watch the options table for those transients being set during checkout.

  • Tom Eagles
    • Syntax Hero

    Hiya, just going through some of the older threads here.

    As it’s been a little while since we last heard from you I thought I’d check in to see how you’re going?

    If you’re still looking for some further assistance with this thread then please feel free to reopen the thread or of course for any new and related issues you are most welcome to open a new thread.



Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.