Post by mikeinterserv » Tue Feb 02, 2021 7:16 pm

I have duplicated the error on a clean install of 3.0.3.2
The problem is the express checkout button module
So no other paypal installed - only paypal express and the express checkout button
Disable the express button module and its fine and paypal payment can be made

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mitrecyclers » Fri Feb 05, 2021 12:09 am

mikeinterserv wrote:
Tue Feb 02, 2021 7:16 pm
I have duplicated the error on a clean install of 3.0.3.2
The problem is the express checkout button module
So no other paypal installed - only paypal express and the express checkout button
Disable the express button module and its fine and paypal payment can be made
You think, upgrading to 3.0.3.6 will resolve this issue?

For all of your Mobile phone needs.
https://mitrecyclers.com


Active Member

Posts

Joined
Tue Sep 25, 2018 5:34 pm

Post by mikeinterserv » Fri Feb 05, 2021 12:20 am

I don't think so
Here is what I think - I may be off the mark but we will see
The paypal express BUTTON is different to the paypal payment module so they both want the api
When you use express BUTTON I think it is designed to go on ANY other page but NOT checkout.
The idea being you don't need it if you are going to go the wholeway through checkout.
BUT others may want to checkout from the product page or the cart etc which is when it BECOMES EXPRESS :-)
So I think maybe it is not designed to be on the checkout page, and if it is I cannot make it work :-)
I am not sure whether going to 3.0.3.6 will fix it as they are very close
If I were you for the time being I would place the button everywhere else other than final checkout it will then work for BOTH of them

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by khnaz35 » Fri Feb 05, 2021 12:34 am

mikeinterserv wrote:
Fri Feb 05, 2021 12:20 am
I don't think so
Here is what I think - I may be off the mark but we will see
The paypal express BUTTON is different to the paypal payment module so they both want the api
When you use express BUTTON I think it is designed to go on ANY other page but NOT checkout.
The idea being you don't need it if you are going to go the wholeway through checkout.
BUT others may want to checkout from the product page or the cart etc which is when it BECOMES EXPRESS :-)
So I think maybe it is not designed to be on the checkout page, and if it is I cannot make it work :-)
I am not sure whether going to 3.0.3.6 will fix it as they are very close
If I were you for the time being I would place the button everywhere else other than final checkout it will then work for BOTH of them
I would suggest place the Express button
On product page after Add to Cart button so customer can quickly buy it.

Got an urgent question that’s keeping you up at night? There might just be a magical inbox ready to help: khnaz35@gmail.com
Enjoy nature ;) :) :-*


User avatar
Active Member

Posts

Joined
Mon Aug 27, 2018 11:30 pm
Location - Malaysia

Post by mitrecyclers » Fri Feb 05, 2021 1:06 am

I finally have to remove that button at all. As even if I add in product page, we still have to use "Add to Cart" button and then refresh page, so paypal button comes in. I hope OpenCart Geniuses will find out solution somehow. :-)

For all of your Mobile phone needs.
https://mitrecyclers.com


Active Member

Posts

Joined
Tue Sep 25, 2018 5:34 pm

Post by mitrecyclers » Fri Feb 05, 2021 1:07 am

Special thanks to mikeinterserv and others who have done extra efforts to debug all this.

For all of your Mobile phone needs.
https://mitrecyclers.com


Active Member

Posts

Joined
Tue Sep 25, 2018 5:34 pm

Post by mikeinterserv » Fri Feb 05, 2021 1:09 am

Obviously you have to add to cart or how would the order be processed otherwise :-)
I will check it to see what you mean. The post above your last mentions the same to add after cart

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 1:10 am

No worries - not going to give up now till you are happy :-)

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 1:16 am

Did you enable the bottom button in paypal express checkout
Well it doesn't matter anyway no change to the result doing it that way. It just takes you to layouts to add to checkout that does not work.
This is why paypal express is no longer being supported

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 1:27 am

You know what - it is very clear what it says here from the module
We recommend offering PayPal Express Shortcut to maximise checkout conversion, this allows customers to use their PayPal address book and checkout is as little as three taps from the basket page. Click enable to install the extension and access the layout manager, you will ned to add "PayPal Express Checkout Button" to the checkout layout

which as you know simply will not work in 3.0.3.2 or 3.0.3.6 nobody has come forward to laugh at us yet - so I think the problem is real :-)

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mitrecyclers » Fri Feb 05, 2021 1:50 am

mikeinterserv wrote:
Fri Feb 05, 2021 1:27 am
You know what - it is very clear what it says here from the module
We recommend offering PayPal Express Shortcut to maximise checkout conversion, this allows customers to use their PayPal address book and checkout is as little as three taps from the basket page. Click enable to install the extension and access the layout manager, you will ned to add "PayPal Express Checkout Button" to the checkout layout

which as you know simply will not work in 3.0.3.2 or 3.0.3.6 nobody has come forward to laugh at us yet - so I think the problem is real :-)
Yes. probably it is.. But Paypal express checkout is very important. as I know, on many websites I prefer to use paypal express checkout instead of following their checkout.. Quick/ Easy and idle for one time users. But we will wait for "Big Boys" to come up with any other solution. Untill then. I will consider it solved. ;-)

For all of your Mobile phone needs.
https://mitrecyclers.com


Active Member

Posts

Joined
Tue Sep 25, 2018 5:34 pm

Post by sw!tch » Fri Feb 05, 2021 4:22 am

How this thread turned into 3 pages?

When you have the PayPal button module on the checkout page, the JS is taking inheritance on button-confirm, hence the same ID is used for confirm order.

You can try renaming the container ID in catalog/view/theme/default/template/extension/module/pp_button.twig

Code: Select all

<div class="panel panel-default">
  <div class="panel-body" style="text-align: right;">
    <div class="buttons">
      <div class="pull-right">
        <a id="paypal-button-confirm" href="{{ payment_url }}"></a>
      </div>
    </div>
  </div>
</div>
<script type="text/javascript"><!--
window.paypalCheckoutReady = function () {
  paypal.checkout.setup('{{ paypal_username }}', {
    container: 'paypal-button-confirm',
    environment: '{{ paypal_environment }}'
  });
};
//--></script>
<script src="//www.paypalobjects.com/api/checkout.js" async></script>
Untested.

-

Full Stack Web Developer :: Send a PM for Custom Work.
Backup and learn how to recover before you make any changes!


Active Member

Posts

Joined
Sat Apr 28, 2012 2:32 pm

Post by mikeinterserv » Fri Feb 05, 2021 4:25 am

Well I shall try it now - and let you know

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 4:36 am

No joy with that either same error exists
PayPal Checkout Integration Script with same version (4.0.323) already loaded on page

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by sw!tch » Fri Feb 05, 2021 4:41 am

Thats not the problem and won't affect the checkout button.

The problem is the OP said the confirm order button doesn't work when using COD.

For the duplicate script, you can try something like:

Code: Select all

<div class="panel panel-default">
  <div class="panel-body" style="text-align: right;">
    <div class="buttons">
      <div class="pull-right">
        <a id="paypal-button-confirm" href="{{ payment_url }}"></a>
      </div>
    </div>
  </div>
</div>
<script type="text/javascript"><!--
window.paypalCheckoutReady = function () {
  paypal.checkout.setup('{{ paypal_username }}', {
    container: 'paypal-button-confirm',
    environment: '{{ paypal_environment }}'
  });
};

if (typeof window.paypal == 'undefined') {
  $.getScript('//www.paypalobjects.com/api/checkout.js');
}
//--></script>
and remove

Code: Select all

<script src="//www.paypalobjects.com/api/checkout.js" async></script>
Someone else will have to test it.

Full Stack Web Developer :: Send a PM for Custom Work.
Backup and learn how to recover before you make any changes!


Active Member

Posts

Joined
Sat Apr 28, 2012 2:32 pm

Post by mikeinterserv » Fri Feb 05, 2021 4:46 am

sw!tch wrote:
Fri Feb 05, 2021 4:41 am
Thats not the problem and won't affect the checkout button.
The problem is the OP said the confirm order button doesn't work when using COD.
I know exactly what the OP said and have duplicated his problem every step of the way including a fresh install of 3.0.3.2 The proble exists that wilth paypal enabled AND the button you get that error. I have spent a lot of time on it - I know you think I'm some sort of idiot but that's not quite it. You cannot pay with bank tranfer while that error exists - the continue is disabled - I will now try your latest suggestion above, assuming me and the OP are stupid is not the way to go because we are not. Why don't you test for yourself what we are saying instead of doubting everything.

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 4:53 am

I am MORE than happy to give you a login with the problem ready to go right now
Just say and I'll PM it

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by sw!tch » Fri Feb 05, 2021 5:10 am

It's hard to help when the forum is being treated as a chat room.

Try the code posted viewtopic.php?f=202&p=813089#p813087

You should be able to just copy and replace into catalog/view/theme/default/template/extension/module/pp_button.twig

Clear your theme cache and see if you are able to replicate.

Not trying to argue with you, when these threads get long with repetitive posts it gets confusing for new users trying to find quick fixes.

You can always PM someone here if you have a question no need to reply to topic over and over.

Full Stack Web Developer :: Send a PM for Custom Work.
Backup and learn how to recover before you make any changes!


Active Member

Posts

Joined
Sat Apr 28, 2012 2:32 pm

Post by mikeinterserv » Fri Feb 05, 2021 5:25 am

OK you did it :-)
That was the fix
not only that but the express button now appears on top of the cart where it did not before
The order works perfectly with paypal enabled and the express button on checkout, so it is fixed for sure.
I can tell you the OP is going to be very happy and I can see where I DID NOT find the error, so thank you it is much appreciated :-)
I just informed the OP and he is very very happy - I gave all credit to you for the fix and us for trying :-)

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales

Post by mikeinterserv » Fri Feb 05, 2021 7:47 am

In short cut and paste the entire file from switches post above
Last edited by mikeinterserv on Fri Feb 05, 2021 8:47 pm, edited 1 time in total.

Active Member

Posts

Joined
Thu May 28, 2020 6:55 am
Location - Wales
Who is online

Users browsing this forum: pprmkr and 69 guests