Problem with Billing addon and Paypal

Discussion in 'Plugins/Modules/Addons' started by Curtis Maurand, Dec 9, 2020.

  1. Hello,
    I seem to have everything configured properly and it's producing a form with what appears to be correct information. When I click on the the button I get a very unhelpful message that reads, "Things don't appear to be working at the moment. Please try again, later.

    I'm not sure what you need from me, please ask and I'll make sure you get it.
    Link to payment page: https://cp.xyonet.com/billing/payments/pay.php?id=
    Paypal email: <[email protected]>
    Paypal URL: https://www.sandbox.paypal.com/cgi-bin/webscr
    Paypal IPN: https://cp.xyonet.com/billing/payments/paypal/ipn.php

    Anyone have any ideas?
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Check the html source of the genereated payment page (the page with the paypal buttons) if any of the variables that get submitted to paypal are empty or look incorrect.
     
  3. The only thing that I can see in all of this is that the value for name looks like it needs to be urlencoded. the email address was valid, I changed it to protect the innocent.


    <div id="paypal">
    <b>Pay with paypal</b>
    <form method="post" name="paypal_form" action="https://www.paypal.com/cgi-bin/webscr">
    <!-- Shopping cart content begin --><p></p>
    <input type="hidden" name="item_name_1" value="Payee: Xyonet powered by Maine Line Systems, Invoice no.:0036I, Invoice date: 2020-12-07">
    <input type="hidden" name="amount_1" value="128.95">
    <input type="hidden" name="quantity_1" value="1">
    <!-- Shopping cart content end --><p></p>
    <input type="hidden" name="upload" value="1">
    <input type="hidden" name="business" value="[email protected]">
    <input type="hidden" name="cmd" value="_cart">
    <input type="hidden" name="no_shipping" value="0">
    <input type="hidden" name="custom" value="0036I">
    <input type="hidden" name="currency_code" value="US">
    <input type="hidden" name="tax" value="0.00">
    <input type="hidden" name="notify_url" value="https://cp.xyonet.com/billing/payments/paypal/ipn.php">
    <input type="hidden" name="return" value="https://cp.xyonet.com/billing/payments/success.php">
    <input type="hidden" name="cancel_return" value="https://cp.xyonet.com/billing/payments/cancel.php">
    <input type="image" src="/billing/lib/btn_paynowCC_LG.gif" name="submit" alt="PayPal - The safer, easier way to pay online!" border="0">

    </form>
    </div>
     
  4. Just went to pay pal to try to trouble shoot the error. The sandbox gave me:
    https://www.sandbox.paypal.com/weba...AMOUNT_ERROR&mfid=1607653215406_f7b5fd3ef6d70

    I changed the company name to Xyonet and dropped the rest of it. This looks like it's going for multi-item button instead of just a single item button. moreover, I can't find any information on the webscr api. It looks like it's been deprecated in favor of a REST API. A nealy incomprehensible API I might add.
     
    Last edited: Dec 11, 2020
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    The form field names are ok, so that's not the reason for your issue in my opinion as it works for years like this on my systems. But you can rename them as a test. The post variables don't have to be url encoded. I can't see any reason why your form fails at the moment.
     
  6. It may have been working for years, but I get this error:
    "Something doesn’t look right. Your payment to this merchant can’t be completed using PayPal. Choose another way to pay."
    On their website they are also saying this:
    'The term "Legacy NVP" refers to the older integration method with PayPal known as Name-Value Pair (NVP) API. This method is being phased out and PayPal recommends upgrading to newer integration methods. For Log in with PayPal legacy integrations (prior to January 2018), you need to replace the '/connect' with '/signin/authorize' in your links. This is an example of how to update the integration for legacy Log in with PayPal. For more details on upgrading your legacy integration, you can refer to the relevant documentation.'

    I can't make the payment bit work at all.
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    I'm using it here, and it still works fine. But if you can't get it to work with your PayPal account, send me a message using our ticket system https://www.ispconfig.org/get-support/?type=billing and I'll refund you the license fee. Just take care to stop using and disable it on your system first.
     
  8. I have a call into paypal. Let's see what they have to say
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    If I do a reimplementation of the payment page for the module in the future, then I'll most likely go with some kind of meta-payment gateway like mollie.com instead of supporting PayPal directly.
     
  10. Cool. Thanks. I got it working. Stupid problem. Currency was set to US instead of USD. That said, the button image link is broken. I have an image that I can use for the button. Can you please tell me which file I should edit to change it? Thanks, Curtis
     
    till likes this.
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    The template file is /usr/local/ispconfig/interface/web/billings/templates/payments_pay.htm
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    I checked the image and it still exists, but I guess the stricter browser policies that are applied to the ISPConfig GUI now prevent that this external image is shown. You might want to download it and store the file in /usr/local/ispconfig/interface/web/billings/templates/images/ and then refer to it in the HTML with an URL like /billing/templates/images/somefile.gif
     
  13. Got the image and put it in the payments folder and linked it in the template. Thanks for your help.
     

Share This Page