Zen Cart Logo
Forums / Addon Payment Modules / Square WebPay support thread.

Square WebPay support thread.

Views: 128,153

Results 181 to 200 of 800
6 Jul 2022, 12:10 AM
#181
carlwhat avatar

carlwhat

zennedOut

Join Date:
Nov 2005
Location:
los angeles
Posts:
2,953
Plugin Contributions:
8

Square WebPay support thread.

Nick1973:

...
Trust me, I have lost orders through this, and I know I have, so I know that it is the issue.

It's easy to replicate if you try it.
nick,
try and play along. i have tried it. numerous times. on your site and on vic's site. did you read the above post:

https://tinyurl.com/2probynf

did you watch the video, i posted:

https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

i have a suggestion for you. why don't you do a screencast similar to what i did, showing the exact sequence where an order goes through using your keystrokes. and then one where it does not.

trust me, there is nothing more that i want to do than to solve this problem. but unless i can replicate it, i can not solve it.

finally with regards to this comment:

It works on the standard checkout, so really it should be the same on OPC.

the only thing i can say is you really have no idea what is going on in OPC and the amount of javascript code that plugin does.

6 Jul 2022, 4:47 AM
#182
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

nick,
try and play along. i have tried it. numerous times. on your site and on vic's site. did you read the above post:

https://tinyurl.com/2probynf

did you watch the video, i posted:

https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

i have a suggestion for you. why don't you do a screencast similar to what i did, showing the exact sequence where an order goes through using your keystrokes. and then one where it does not.

trust me, there is nothing more that i want to do than to solve this problem. but unless i can replicate it, i can not solve it.

finally with regards to this comment:

It works on the standard checkout, so really it should be the same on OPC.

the only thing i can say is you really have no idea what is going on in OPC and the amount of javascript code that plugin does.

carlwhat, I am playing along and this is why I am also reporting the issue :-)

Ok Screencast - will do one then so you can see the issue. I guess from our points of view we could be reading things differently from one another after all so not an issue.

'the only thing i can say is you really have no idea what is going on in OPC and the amount of javascript code that plugin does' - I do know the amount of Javascript that is used by OPC, so I am fully aware it will be a minefield to work with.

Like I said before carlwhat, I am extremely grateful for your hard work on this, and I think Vic is from what I read as well. There are probably others that think the same.

6 Jul 2022, 5:46 AM
#183
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

nick,
try and play along. i have tried it. numerous times. on your site and on vic's site. did you read the above post:

https://tinyurl.com/2probynf

did you watch the video, i posted:

https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

i have a suggestion for you. why don't you do a screencast similar to what i did, showing the exact sequence where an order goes through using your keystrokes. and then one where it does not.

trust me, there is nothing more that i want to do than to solve this problem. but unless i can replicate it, i can not solve it.

finally with regards to this comment:

It works on the standard checkout, so really it should be the same on OPC.

the only thing i can say is you really have no idea what is going on in OPC and the amount of javascript code that plugin does.

Ok I have had a look at your screencast videos.

Firstly, I understand why the Paypal method would fail, so that is fine because the customer has selected the wrong payment method and then tried to enter details into the square fields. You would expect that to fail!

That is this video:
https://www.dropbox.com/s/6mc9y5gvf3biolj/Screencast%20from%2007-04-2022%2004%3A42%3A02%20PM.webm?dl=0


Now, this video actually highlights the problem:
https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

So, a suggestion. To stop this from happening, are you able to force the customer to select the radio button before they can enter their details?

You could disable the SQUARE text entry fields, or even hide them until customers click on the SQUARE radio button. And if customers click the Paypal radio button, the text fields on the square element either remain disabled or hidden from view.

At the side of the SQUARE radio button in BOLD text, or even BOLD RED TEXT, you could have some text saying 'If you wish to pay by credit or debit card, please select this payment method. NOTE: You will be able to enter your payment details once this radio button is checked' - then once the radio button is clicked, the text fields either get enabled OR if hidden, they appear on screen.

At the side of the PAYPAL radio button you could have some text saying 'If you wish to pay by PAYPAL, please select this payment method' - then the SQUARE text fields either remain disabled or hidden from view and the customer can pay by paypal without a problem.

And if the customer happens to try and click confirm order, before they have selected either, it throws up a message something like 'You forgot to select a payment method, please try again'.

This is just an idea by the way! I am trying to help with a suggestion!

6 Jul 2022, 6:34 AM
#184
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

Nick1973:

Ok I have had a look at your screencast videos.

Firstly, I understand why the Paypal method would fail, so that is fine because the customer has selected the wrong payment method and then tried to enter details into the square fields. You would expect that to fail!

That is this video:
https://www.dropbox.com/s/6mc9y5gvf3biolj/Screencast%20from%2007-04-2022%2004%3A42%3A02%20PM.webm?dl=0


Now, this video actually highlights the problem:
https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

So, a suggestion. To stop this from happening, are you able to force the customer to select the radio button before they can enter their details?

You could disable the SQUARE text entry fields, or even hide them until customers click on the SQUARE radio button. And if customers click the Paypal radio button, the text fields on the square element either remain disabled or hidden from view.

At the side of the SQUARE radio button in BOLD text, or even BOLD RED TEXT, you could have some text saying 'If you wish to pay by credit or debit card, please select this payment method. NOTE: You will be able to enter your payment details once this radio button is checked' - then once the radio button is clicked, the text fields either get enabled OR if hidden, they appear on screen.

At the side of the PAYPAL radio button you could have some text saying 'If you wish to pay by PAYPAL, please select this payment method' - then the SQUARE text fields either remain disabled or hidden from view and the customer can pay by paypal without a problem.

And if the customer happens to try and click confirm order, before they have selected either, it throws up a message something like 'You forgot to select a payment method, please try again'.

This is just an idea by the way! I am trying to help with a suggestion!

Right I am going to try a couple of things. Firstly I am going to run one of my carts with OPC switched off for a day.

Then I am going to run the cart for a day with OPC on, and put some text next to the Square Radio Button saying 'If you wish to pay by credit or debit card, please select this payment method. NOTE: Please ensure you click the radio button before entering your card details, otherwise your transaction will fail' - stating the obvious!

And against the Paypal radio button - some text saying 'If you wish to pay by PAYPAL, please select this payment method, and then click 'Confirm Order' at the bottom of this page'

I know it may sound rediculous but there are 'some' customers that need instructions, where we may think it is obvious what to do.

6 Jul 2022, 2:33 PM
#185
carlwhat avatar

carlwhat

zennedOut

Join Date:
Nov 2005
Location:
los angeles
Posts:
2,953
Plugin Contributions:
8

Re: Square WebPay support thread.

Nick1973:

Now, this video actually highlights the problem:
https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0

So, a suggestion. To stop this from happening, are you able to force the customer to select the radio button before they can enter their details?

no, nick. you are wrong. that video does NOT highlight the problem. that video shows what YOU think is the problem. and in my testing, doing the exact keystrokes that you talk about, the problem does not manifest itself. that video clearly shows that.

in answer to your above suggestion, that is not possible. again that is inherent in square's implementation.

Nick1973:

This is just an idea by the way! I am trying to help with a suggestion!

carlwhat:

i have a suggestion for you. why don't you do a screencast similar to what i did, showing the exact sequence where an order goes through using your keystrokes. and then one where it does not.

why don't you take the time for my suggestion as opposed to making additional suggestions? perhaps your video would more clearly delineate the steps for this problem to occur.

6 Jul 2022, 2:41 PM
#186
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

no, nick. you are wrong. that video does NOT highlight the problem. that video shows what YOU think is the problem. and in my testing, doing the exact keystrokes that you talk about, the problem does not manifest itself. that video clearly shows that.

in answer to your above suggestion, that is not possible. again that is inherent in square's implementation.

why don't you take the time for my suggestion as opposed to making additional suggestions? perhaps your video would more clearly delineate the steps for this problem to occur.

Well if you think that isn't a problem, then you clearly are blind as it clearly is a problem. I even have clients complaining about this now actually and am having to switch off OPC for them as a result.

'in answer to your above suggestion, that is not possible. again that is inherent in square's implementation.' - well if that is the case, then why does it work with the standard zen cart checkout without those issues but not with OPC? I am struggling here as one works, the other doesn't.

6 Jul 2022, 2:44 PM
#187
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

no, nick. you are wrong. that video does NOT highlight the problem. that video shows what YOU think is the problem. and in my testing, doing the exact keystrokes that you talk about, the problem does not manifest itself. that video clearly shows that.

in answer to your above suggestion, that is not possible. again that is inherent in square's implementation.

why don't you take the time for my suggestion as opposed to making additional suggestions? perhaps your video would more clearly delineate the steps for this problem to occur.

Look your video does clearly show the problem, I am amazed that you can't even see it?

Those strokes are the exact ones that I tried. And also I tried without OPC, the same strokes. Without OPC the payment goes through, with OPC it doesn't.

6 Jul 2022, 4:03 PM
#188
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

no, nick. you are wrong. that video does NOT highlight the problem. that video shows what YOU think is the problem. and in my testing, doing the exact keystrokes that you talk about, the problem does not manifest itself. that video clearly shows that.

in answer to your above suggestion, that is not possible. again that is inherent in square's implementation

why don't you take the time for my suggestion as opposed to making additional suggestions? perhaps your video would more clearly delineate the steps for this problem to occur.

I don't know why but I can't get a screencast at the moment anyway. But in it's simplest terms, try the exact same strokes as in your video on the standard checkout, and you will see the issue. You will see on the standard checkout, payments go through no problem. On OPC, they do not!

Customers complaining that they can't pay through OPC are the one's which decide if there is an issue. If they can't pay, there is an issue. I am going to try sticking instructional text next to each radio button to state the obvious, and I do understand your point in some ways. Clicking the radio button should be common sense. However, customers don't always think with common sense. And those are the people that tell us if they are having problems making payments through the checkout.

The other issue is, even if I put instructional text next to those radio buttons, there will be some that still start entering card details and think it has automatically selected the radio button, and therefore they will still get the error and then click off and go somewhere else to get what they want.

For me at the moment, the standard checkout works better than OPC with Square, which is a great shame as OPC is the better one. Although it has got a bit sluggish to be honest and hangs in a place or two.

6 Jul 2022, 4:55 PM
#189
carlwhat avatar

carlwhat

zennedOut

Join Date:
Nov 2005
Location:
los angeles
Posts:
2,953
Plugin Contributions:
8

Re: Square WebPay support thread.

Nick1973:

Look your video does clearly show the problem, I am amazed that you can't even see it?

Those strokes are the exact ones that I tried. And also I tried without OPC, the same strokes. Without OPC the payment goes through, with OPC it doesn't.

i would suggest these things:

  • review the above post. https://tinyurl.com/2probynf
  • post a screencast your self documenting the error.
  • review this statement from the above mentioned post:
  • with regards to the 2 situations you mention above, i have a couple of videos. **a GENERIC DECLINE is coming back from square. **the SQ-MISSING-TOKEN error is an error from square_webPay as we are not submitting anything to square as we do not have the result from the first step of the process.
  • my screencast clearly shows communication from square. not a missing token.
6 Jul 2022, 5:09 PM
#190
simon1066 avatar

simon1066

Totally Zenned

Join Date:
Feb 2009
Location:
UK
Posts:
1,326
Plugin Contributions:
0

Re: Square WebPay support thread.

[06-Jul-2022 17:51:21 Europe/London] PHP Notice:  missing token result:  check if card button is disabled on dev console using: document.getElementById('card-button'); else look for javascript error in console. in /home/my_vps/public_html/includes/modules/payment/square_webPay.php on line 234

ZC v1.5.7d
OPC v2.4.1
PayPal EC

Testing Square WebPay on a live site for the first time. Forgive me for not fully following the previous posts regarding this error/notice but to explain simply (I hope):

Checking out as a guest and using Square WebPay as the payment method I enter the CC info and click the Confirm button, the checkout_one page refreshes showing the SQ-MISSING-TOKEN error message with the above PHP notice in the \logs folder. It makes no difference if I first click the Square radio button or go straight to entering CC info.

I have tried renewing the token manually (mywebsite.co.uk/squareWebPay_handler.php) and nothing looks awry, to me, in the browser's console - everything is returning 200 OK.

I am open to any debug suggestions.

6 Jul 2022, 5:16 PM
#191
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

carlwhat:

i would suggest these things:

  • post a screencast your self documenting the error.
  • review this statement from the above mentioned post:
  • with regards to the 2 situations you mention above, i have a couple of videos. **a GENERIC DECLINE is coming back from square. **the SQ-MISSING-TOKEN error is an error from square_webPay as we are not submitting anything to square as we do not have the result from the first step of the process.
  • my screencast clearly shows communication from square. not a missing token.

Yep and around in circles we go again lol

Try the same method on the standard checkout and you will clearly see the issue.

I have customers telling me they can't checkout using OPC with Square Webpay because they get the SQ-MISSING-TOKEN error. They don't understand that error as they are not technically minded.

The minute they checkout using the standard zen cart checkout, there isn't an error. It works! Therefore something isn't quite right.

6 Jul 2022, 5:26 PM
#192
simon1066 avatar

simon1066

Totally Zenned

Join Date:
Feb 2009
Location:
UK
Posts:
1,326
Plugin Contributions:
0

Re: Square WebPay support thread.

simon1066:

[06-Jul-2022 17:51:21 Europe/London] PHP Notice: missing token result: check if card button is disabled on dev console using: document.getElementById('card-button'); else look for javascript error in console. in /home/my_vps/public_html/includes/modules/payment/square_webPay.php on line 234

> 
> ZC v1.5.7d
> OPC v2.4.1
> PayPal EC
> 
> Testing Square WebPay on a live site for the first time. Forgive me for not fully following the previous posts regarding this error/notice but to explain simply (I hope):
> 
> Checking out as a guest and using Square WebPay as the payment method I enter the CC info and click the Confirm button, the checkout_one page refreshes showing the SQ-MISSING-TOKEN error message with the above PHP notice in the \logs folder. It makes no difference if I first click the Square radio button or go straight to entering CC info.
> 
> I have tried renewing the token manually (mywebsite.co.uk/squareWebPay_handler.php) and nothing looks awry, to me, in the browser's console - everything is returning 200 OK. 
> 
> I am open to any debug suggestions.

Screenshot of the Console:

Edit: removing image I'll repost with my oauth details removed.
6 Jul 2022, 5:43 PM
#193
valencia avatar

valencia

New Zenner

Join Date:
Jul 2010
Location:
England
Posts:
17
Plugin Contributions:
0

Re: Square WebPay support thread.

carlwhat:

hi vic,
i wish these situations were the case. i am not able to reproduce it on your site. i am only able to fix what i can reproduce.

allow me to explain a little bit about this process: it is a 2-step process; the first step sends the credit card data to square, it returns a token. square_webPay takes this token, adds it onto the html form on the OPC page, and then submits the whole form to your zen-cart installation. at that point, ZC has control, and then ZC submits that token to square.

if for whatever reason that token does NOT make it onto the html form, you see the error that you are getting.

with regards to the 2 situations you mention above, i have a couple of videos. a GENERIC DECLINE is coming back from square. the SQ-MISSING-TOKEN error is an error from square_webPay as we are not submitting anything to square as we do not have the result from the first step of the process:

https://www.dropbox.com/s/i3zc3t5diuduhbw/Screencast%20from%2007-04-2022%2004%3A40%3A01%20PM.webm?dl=0
https://www.dropbox.com/s/6mc9y5gvf3biolj/Screencast%20from%2007-04-2022%2004%3A42%3A02%20PM.webm?dl=0

you are correct here. the previous module selected the radio button the moment you touched the input fields. the webPay module selects the radio button after the first input, and NOT when a field gets focused.

unfortunately that is impossible to change due to the architecture of the new square infrastructure. it was something that i remember looking at rather closely. but again this is not the problem as one can see from my videos.

that said, i DO appreciate the troubleshooting with the specific keystrokes that you think are causing the problem. if we are able to reproduce it, we can then fix it.

best.

Hi Carl,

I have posted three videos of the following scenarios that I hope might help. They are from the same live site you tested on and unchanged in any way.

No Radio button selected, card data entered directly. returns SQ_Missing_Token
https://drive.google.com/file/d/16BiEB1kj1a2l5KRw0WwoU1GvbbZFj7I3/view?usp=sharing

Radio Button Selected by user then card data entered returns Generic_Decline
https://drive.google.com/file/d/1mrOzL8ddl5YZZAO1MpXAioxPf4zUB6_Q/view?usp=sharing

After getting SQ_Missing_Token card data entered immediately again giving Generic_Decline
https://drive.google.com/file/d/1RpEXJsmX7mAH4zR-NqgsQkKR0Y5nsYBW/view?usp=sharing

I hope it can be of help to visually see the results.

Also when I turn off OPC and have the standard checkout process, entering the card details directly into the card fields without selecting the radio button, gives the positive result the Generic_Decline.

Hope the results are useful.

Kind regards

Vic :smile:

6 Jul 2022, 6:12 PM
#194
nick1973 avatar

nick1973

Totally Zenned

Join Date:
Sep 2008
Location:
Cleethorpes
Posts:
1,230
Plugin Contributions:
3

Re: Square WebPay support thread.

Valencia:

Hi Carl,

I have posted three videos of the following scenarios that I hope might help. They are from the same live site you tested on and unchanged in any way.

No Radio button selected, card data entered directly. returns SQ_Missing_Token
https://drive.google.com/file/d/16BiEB1kj1a2l5KRw0WwoU1GvbbZFj7I3/view?usp=sharing

Radio Button Selected by user then card data entered returns Generic_Decline
https://drive.google.com/file/d/1mrOzL8ddl5YZZAO1MpXAioxPf4zUB6_Q/view?usp=sharing

After getting SQ_Missing_Token card data entered immediately again giving Generic_Decline
https://drive.google.com/file/d/1RpEXJsmX7mAH4zR-NqgsQkKR0Y5nsYBW/view?usp=sharing

I hope it can be of help to visually see the results.

Also when I turn off OPC and have the standard checkout process, entering the card details directly into the card fields without selecting the radio button, gives the positive result the Generic_Decline.

Hope the results are useful.

Kind regards

Vic :smile:

This is what I am getting with OPC:

No Radio button selected, card data entered directly. returns SQ_Missing_Token
https://drive.google.com/file/d/16Bi...ew?usp=sharing

If the radio button is checked before entering the card details, the payment works. If it isn't checked, it doesn't work. Your video highlights the this scenario.

If you do the the same process on the standard checkout, it works perfectly as it should.

11 Jul 2022, 1:50 PM
#195
delia avatar

delia

Totally Zenned

Join Date:
May 2006
Location:
Gardiner, Maine
Posts:
2,383
Plugin Contributions:
7

Re: Square WebPay support thread.

in trying to activate the token this error is being generated:
[11-Jul-2022 08:42:47 America/Chicago] Request URI: /squareWebPay_handler.php?code=sq0cgp-hSqjZnDct9f2STlglgrcSQ&response_type=code&state=7797894d5590c14fe34769c3199a7d858dbc1c6646e6b65a1f1589a6bf27439a, IP address: 66.232.98.194
--> PHP Fatal error: Uncaught Error: Class 'Square\Models\ObtainTokenRequest' not found in /includes/modules/payment/square_webPay.php:690
Stack trace:
#0 /squareWebPay_handler.php(33): square_webPay->exchangeForToken('sq0cgp-hSqjZnDc...')
#1 {main}
thrown in /includes/modules/payment/square_webPay.php on line 690.

I checked and made sure all the files were uploaded and the old module removed.

11 Jul 2022, 3:09 PM
#196
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,763
Plugin Contributions:
9

Re: Square WebPay support thread.

delia:

I checked and made sure all the files were uploaded and the old module removed.If you actually removed the files from their locations, that can be part of the problem.

The best way is to have all the files on the site but, don't click on install.

If all the old files are on the site, go to the circled i for the old square. If it says Install Module, all is fine. If not, click on Remove Module which actually leaves needed files on the site.

11 Jul 2022, 3:16 PM
#197
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,682
Plugin Contributions:
56

Re: Square WebPay support thread.

Getting emails saying

Authorization error: 'VOICE_FAILURE' Sent to Square: SquareModelsCreatePaymentRequest Object ....

Sometimes the charge succeeds on retry; other times the customer has to switch to PayPal or some other payment method.

11 Jul 2022, 3:17 PM
#198
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,682
Plugin Contributions:
56

Re: Square WebPay support thread.

I guess what I'm wondering is, if it's possible to deduce that you're in this state and give a message to the customer in the cart.

11 Jul 2022, 3:40 PM
#199
carlwhat avatar

carlwhat

zennedOut

Join Date:
Nov 2005
Location:
los angeles
Posts:
2,953
Plugin Contributions:
8

Re: Square WebPay support thread.

swguy:

I guess what I'm wondering is, if it's possible to deduce that you're in this state and give a message to the customer in the cart.

how do you know i'm not already doing that?

error messages are already added to the message stack and displayed to the customer. see:

https://github.com/proseLA/square_webPay/blob/4539aaa0f2f7cc6b5422780b2da5b484fdc54bef/for_upload/includes/modules/payment/square_webPay.php#L428-L433

line 431.

11 Jul 2022, 5:08 PM
#200
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,682
Plugin Contributions:
56

Re: Square WebPay support thread.

@carlwhat is maintaining the Square plugin; please don't post information about your fork - it's disrespectful and confusing to new people.
I will immediately delete such posts.