Jump to content

PayPal Commerce


CubeCart Bot

Recommended Posts

Hi, i'm about to make the connection to Paypal in PPC plugin. I have a business profil already on Paypal. After it connects, PPC (or Paypal?) still asking some further info about the company. Fine. However to this question i don't find the right answer format:

What is the business registration number of the business?
You will find this in the memorandum of association.

I have this number but always getting back an error as it is not fine. So my question is what format or how many numbers/letters should be there to be fine. Thanks a lot in advance for every relevat answer.

Edited by stabal
Link to comment
Share on other sites

  • 2 weeks later...

Hello Al,

This topic started with the choice of payment gateway priority and you mentioned:

Quote

I don't see why we can't add a setting for this to be default or not from the extension settings page to be honest.

Will you be adding this feature to the extension? I too would prefer to have the choice.

For me fee wise PayPal is similar to Opayo/Sagepay.

Link to comment
Share on other sites

Does PP Commerce still have the ability to override the customers address details.

Al has suggested switching to commerce, but i'm nervous in the respcet that previous incarnations got us in to no end of trouble numerous times.

 

Using his personal paypal account, buyer makes a purchase for work,

PayPal over rides the delivery address.

We send a pallet of goods to the wrong address.

Goods inviraiable come back to us 2 days later, where we have to re-arrange shipment.

Customer is not best pleased, as a next day delivery has just taken a week.

Link to comment
Share on other sites

  • 1 month later...

I have tried to use this plugin to no avail.

In the admin backend, in the extensions section, clicking on Paypal Commerce to configure it simply gives a browser error of "redirected too many times"

[Wed Apr 06 16:52:43.531290 2022] [php7:warn] [pid 18937] [client 82.163.190.249:60111] PHP Warning:  Invalid argument supplied for foreach() in /var/www/www.bigjimny.com/public_html/store/modules/plugins/paypal_commerce/admin/index.inc.php on line 188, referer: http://www.bigjimny.com/store/admin_yj0SXd.php?_g=plugins
[Wed Apr 06 16:52:44.365731 2022] [php7:warn] [pid 17608] [client 82.163.190.249:60113] PHP Warning:  Invalid argument supplied for foreach() in /var/www/www.bigjimny.com/public_html/store/modules/plugins/paypal_commerce/admin/index.inc.php on line 188, referer: http://www.bigjimny.com/store/admin_yj0SXd.php?_g=plugins
[Wed Apr 06 16:52:45.198098 2022] [php7:warn] [pid 17607] [client 82.163.190.249:60115] PHP Warning:  Invalid argument supplied for foreach() in /var/www/www.bigjimny.com/public_html/store/modules/plugins/paypal_commerce/admin/index.inc.php on line 188, referer: http://www.bigjimny.com/store/admin_yj0SXd.php?_g=plugins

 

Edited by Martin Lines
Link to comment
Share on other sites

Line 188 wants to iterate through a collection of $webhooks. That collection comes from a request being made to PayPal for a list of available webhooks.

That request should be logged in CubeCart's admin, Request Log.

Please examine the Request Log, find the appropriate logged Request/Response entries, and determine if the Response indicates what could be wrong.

Link to comment
Share on other sites

Here is a grab of the Request Log

 

oday, 09:12
Request Sent (cURL) - https://api.paypal.com/v1/notifications/webhooks{ "url": "http://www.bigjimny.com/store/index.php?_g=rm&type=plugins&cmd=call&module=paypal_commerce", "event_types": [ { "name": "PAYMENT.CAPTURE.COMPLETED" }, { "name": "PAYMENT.CAPTURE.REVERSED" }, { "name": "PAYMENT.CAPTURE.REFUNDED" }, { "name": "PAYMENT.AUTHORIZATION.VOIDED" }, { "name": "PAYMENT.CAPTURE.DENIED" }, { "name": "CHECKOUT.ORDER.APPROVED" }, { "name": "CHECKOUT.ORDER.COMPLETED" }, { "name": "PAYMENT.CAPTURE.PENDING" }, { "name": "PAYMENT.AUTHORIZATION.CREATED" } ] }
Error:cURL Error (22): The requested URL returned error: 400 Bad Request
Response received (400 - Bad Request)
Today, 09:12
Error:cURL Error (22): The requested URL returned error: 405 Method Not Allowed
Response received (405 - Method Not Allowed)
Today, 09:12
Response received (200 - OK){"webhooks":[]}
Today, 09:12
Request Sent (cURL) - https://api.paypal.com/v1/notifications/webhooks{ "url": "http://www.bigjimny.com/store/index.php?_g=rm&type=plugins&cmd=call&module=paypal_commerce", "event_types": [ { "name": "PAYMENT.CAPTURE.COMPLETED" }, { "name": "PAYMENT.CAPTURE.REVERSED" }, { "name": "PAYMENT.CAPTURE.REFUNDED" }, { "name": "PAYMENT.AUTHORIZATION.VOIDED" }, { "name": "PAYMENT.CAPTURE.DENIED" }, { "name": "CHECKOUT.ORDER.APPROVED" }, { "name": "CHECKOUT.ORDER.COMPLETED" }, { "name": "PAYMENT.CAPTURE.PENDING" }, { "name": "PAYMENT.AUTHORIZATION.CREATED" } ] }
Error:cURL Error (22): The requested URL returned error: 400 Bad Request
Response received (400 - Bad Request)
Today, 09:12
Error:cURL Error (22): The requested URL returned error: 405 Method Not Allowed
Response received (405 - Method Not Allowed)
Today, 09:12
Response received (200 - OK){"webhooks":[]}
Today, 09:12
Response received (200 - OK){"webhooks":[]}
Today, 09:12
Request Sent (cURL) - https://api.paypal.com/v1/notifications/webhooks{ "url": "http://www.bigjimny.com/store/index.php?_g=rm&type=plugins&cmd=call&module=paypal_commerce", "event_types": [ { "name": "PAYMENT.CAPTURE.COMPLETED" }, { "name": "PAYMENT.CAPTURE.REVERSED" }, { "name": "PAYMENT.CAPTURE.REFUNDED" }, { "name": "PAYMENT.AUTHORIZATION.VOIDED" }, { "name": "PAYMENT.CAPTURE.DENIED" }, { "name": "CHECKOUT.ORDER.APPROVED" }, { "name": "CHECKOUT.ORDER.COMPLETED" }, { "name": "PAYMENT.CAPTURE.PENDING" }, { "name": "PAYMENT.AUTHORIZATION.CREATED" } ] }
Error:cURL Error (22): The requested URL returned error: 400 Bad Request
Response received (400 - Bad Request)
Today, 09:12
Error:cURL Error (22): The requested URL returned error: 405 Method Not Allowed
Response received (405 - Method Not Allowed)
Today, 09:12
Response received (200 - OK){"webhooks":[]}
Today, 09:12
Request Sent (cURL) - https://api.paypal.com/v1/notifications/webhooks{ "url": "http://www.bigjimny.com/store/index.php?_g=rm&type=plugins&cmd=call&module=paypal_commerce", "event_types": [ { "name": "PAYMENT.CAPTURE.COMPLETED" }, { "name": "PAYMENT.CAPTURE.REVERSED" }, { "name": "PAYMENT.CAPTURE.REFUNDED" }, { "name": "PAYMENT.AUTHORIZATION.VOIDED" }, { "name": "PAYMENT.CAPTURE.DENIED" }, { "name": "CHECKOUT.ORDER.APPROVED" }, { "name": "CHECKOUT.ORDER.COMPLETED" }, { "name": "PAYMENT.CAPTURE.PENDING" }, { "name": "PAYMENT.AUTHORIZATION.CREATED" } ] }
Error:cURL Error (22): The requested URL returned error: 400 Bad Request
Response received (400 - Bad Request)
Today, 09:12
Error:cURL Error (22): The requested URL returned error: 405 Method Not Allowed
Response received (405 - Method Not Allowed)
Today, 09:12
Error:cURL Error (22): The requested URL returned error: 405 Method Not Allowed
Response received (405 - Method Not Allowed)
Edited by Martin Lines
Link to comment
Share on other sites

  • 1 month later...

This extension seems to be glitchy still..

Today we have had more than one occasion where the response is

Today, 15:59
Request Sent (cURL) - https://api.paypal.com/v2/checkout/orders/4BU53633E89179603[{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/amount","value":{"value":"71.10","currency_code":"GBP","breakdown":{"item_total":{"value":"66.35","currency_code":"GBP"},"shipping":{"value":"4.75","currency_code":"GBP"},"tax_total":{"value":"0","currency_code":"GBP"},"discount":{"value":"0","currency_code":"GBP"}}}},{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/shipping/name","value":{"full_name":"xxxxxx"}},{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/shipping/address","value":{"address_line_1":"xxxxxxxxxx","address_line_2":"xxxxxxxx","admin_area_1":"Undefined","admin_area_2":"xxxxxxxxxx","postal_code":"xxxxxxxx","country_code":"GB"}}]
Response received (204 - No Content)
Today, 15:56
Request Sent (cURL) - https://api.paypal.com/v2/checkout/orders/4BU53633E89179603[{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/amount","value":{"value":"71.10","currency_code":"GBP","breakdown":{"item_total":{"value":"66.35","currency_code":"GBP"},"shipping":{"value":"4.75","currency_code":"GBP"},"tax_total":{"value":"0","currency_code":"GBP"},"discount":{"value":"0","currency_code":"GBP"}}}},{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/shipping/name","value":{"full_name":"xxxxxxxx"}},{"op":"replace","path":"/purchase_units/@reference_id=='6282651aaeb56'/shipping/address","value":{"address_line_1":"xxxxxxxxx","address_line_2":"xxxxxxxxxxx","admin_area_1":"Undefined","admin_area_2":"xxxxxxxxx","postal_code":"xxxxxxx","country_code":"GB"}}]
Response received (204 - No Content)
 
Needless to say some lost sales and two frustrated customers on the phone :-(

 

Edited by Tony
Hidden customer address
Link to comment
Share on other sites

  • 9 months later...

I don't see any of the Pay Later messaging showing up in any skin and I can only get the paypal button to appear in Foundation on the product page itself.

thought I had one of them sorted it needs a change to "config.foundation.json" but it flickers  up for a second then outputs a crap load of errors;

{description: 'Expected one of ["home", "category", "product", "cart", "payment"] but received "$placement".', location: 'placement', timestamp: '1677596745015'}

js?client-id=AeYlxqQ3Mm1IkVdrJQL2tr0nh8qDl6_lWosWnZh_kK2nMZuNYhLzMLO9_6t1yuSVf9uephcoudClXpa0&merchant-id=URJL4JF9VRTT8&currency=EUR&components=messages,buttons&enable-funding=paylater&commit=false:2 unhandled_error {err: 'Error: zoid destroyed all components\n    at https:…ns&enable-funding=paylater&commit=false:2:447499)', timestamp: '1677596745184', referer:

Edited by Lastwolf
Link to comment
Share on other sites

The PayLater messaging appears to be cause I don't have it enabled on that paypal account, so that would explain that 😃

 

Still can't get the alternative Paypal buy button to show up for more than a few seconds, with my attempts to cheat

"product":{"dom":".product_wrapper #main_content form .row .row:last-child"}

even changing that to just be the id of the div, causes the above errors.

It also doesn't show on the main page, just category and checkout. I figured it was because dillion removed the #main_content id, but even adding it back made no difference.

Edited by Lastwolf
Link to comment
Share on other sites

yeah, I figured that, so is this section to display the element only were all things are true and display it there?

cause I can see to get it to post for like half a second then it goes away with this $placement issue, which appears to be some bootstrap thing.

Link to comment
Share on other sites

Please try this:

In the PayPal Commerce module, create a new file:

Name:
config.dillion.json

Contents:
{"home":{"dom":".home_wrapper"},"category":{"dom":".category_wrapper"},"product":{"dom":".product_wrapper .page-body-content form .row .row:last-child"},"payment": {"dom":"#checkout_actions"},"cart": {"dom":"#checkout_actions"}}

The module looks for 'config.custom.json', but if not found will look for 'config.SKIN_NAME.json', but if not found will look for 'config.foundation.json'.

The JSON data extracted from this file is cached.

This JSON array just uses the specific wrapper name for all but the product page, because the product page placement is (should be) directly under the 'call-to-action' block (price, quantity, add button).

Dillion does not have a #main_content node.

Link to comment
Share on other sites

In the PayPal Commerce module file /hooks/class.gui.head_js.php:

Near line 98, find:

var messaging = '$messaging';

On the same line, after that statement, add:

console.log('Location: '+pp_config.$placement.dom);

Then, in the browser's console viewer, there should be a Location: something message.

Link to comment
Share on other sites

  • 2 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...