2CO won't work with Membership plugin-'There was a problem connecting to 2CO. Please try a

I am using Business Portfolio child with Wordpress 3.0.4 and BuddyPress.

I cannot get my new 2CO account to work with the membership subscribe function. I have set up the subscriptions, have added the products to the 2CO site (I can generate buttons and HTML code, but I want it to work when someone subscribes--if I am supposed to put that code somewhere I sure don't know where). I have activated the gateway and made it public.

I have looked through all of the forums and done everything advised to solve this problem. I have downloaded and installed a new php file as suggested in one forum answer. (Attachments .[zip] gateway.twocheckout.php.zip (3.8 KB, 1 downloads) 11 hours old ).

I have added a new API user and put that in the 2CO settings on my site. Whenever I test the subscribe function I get a notice next to the item---There was a problem connecting to 2CO. Please try again. I have attached a screen shot.

Please advise. Thanks.

  • JoAnn
    • The Incredible Code Injector

    I'm not sure how much you need after REF, but here is some. If you need more, let me know.

    print __('There was a problem connecting to 2CO. Please try again.
    REF:'.wp_remote_retrieve_response_code($response), 'membership');
    } else {
    $response_obj = json_decode($response['body']);

    $found = false;

    if ($response_obj->products && is_array($response_obj->products) && count($response_obj->products) > 0) {
    foreach ($response_obj->products as $product) {
    if ($subscription->sub_id() == $product->vendor_product_id) {
    $found = true;

  • Barry
    • DEV MAN’s Mascot

    @JoAnn - he means that when you get an error back after you have made the changes it will look like:

    There was a problem connecting to 2CO. Please try again. REF: The error here

    He needs the bit where I've put "The error here" (the bit after REF:slight_smile: in order to work out what is happening on your system.

  • JoAnn
    • The Incredible Code Injector

    Okay, in the membership, edit gateways, under 2CheckOut settings I changed the user name to my regular login user name rather than just the API user name and got this error:

    There was a problem connecting to 2CO. Please try again. REF:403

  • JoAnn
    • The Incredible Code Injector

    I can only surmise that I am simply setting everything up completely wrong.

    Where can I get detailed instructions for setting up 2CO to integrate with my membership plugin and to allow choices for my members to choose from, such as:

    Monthly recurring billing
    Quarterly recurring billing
    Semi-annual recurring billing
    Annual recurring billing

    I have set these up in the list products area in 2CO. These will generate codes for buttons or links. If I put the button or link in a Wordpress page it works fine, but I want to offer choices for my members when they click the 'Subscribe' button on my home page of the Business Portfolio theme.

    I am totally lost here as to how to accomplish this. I do apologize, but I have never set up anything like this before.

  • JoAnn
    • The Incredible Code Injector

    I fiddled around with the API settings on the 2CO site and finally got it working.

    If anyone else has this problem you need to set up a new user on the 2CO site and give that user API access and API updating. Put that user name and password in the gateway settings for the 2CheckOut user name and 2CheckOut user password.

    That did it for me. Any other combination of settings, including putting in my original sign in user name and password did not work.

    I'm done for the night before I find any other problems.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.