Author Topic: Cart not diverting to PayPal redirect to home page  (Read 1170 times)

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Cart not diverting to PayPal redirect to home page
« on: March 11, 2020, 22:21:42 pm »
Changed server (Checked with hosting and the errors are pointing to VM) When adding items to cart in VM then select payment it brings up "Please wait redirecting to PayPal" all good to this point but then diverts to home page. My site s running Joomla 3.9.16 PHP 7.3 Virtuemart 3.6.10 PayPal standard is the payment plugin. Testing this after being diverted to the home page if I delete browsing history front end then select the home page it takes me to PayPal payment page!
Has anyone experience this problem and if so how to fix?

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #1 on: March 11, 2020, 22:59:24 pm »
Its a very simple redirect ..

just submits the form

           jQuery(document).ready(function($){
               jQuery("body").addClass("vmLoading");
              var msg="'.$msg.'";
               jQuery("body").append("<div class=\"vmLoadingDiv\"><div class=\"vmLoadingDivMsg\">"+msg+"</div></div>");
             jQuery("#vmPaymentForm").submit();
         })

so switch the paypal debug on and check all the form elements are correctly set and the form action correct
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #2 on: March 13, 2020, 06:06:36 am »
The paypal error report is not showing any problems see attached screenshot.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #3 on: March 13, 2020, 09:15:25 am »
and when u subsequently submit it?

check the console Network tab for progress etc
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #4 on: March 13, 2020, 09:29:10 am »
I'm looking at the processes, is there something I should see that tells me there is a problem? see screenshots.

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #5 on: March 13, 2020, 09:37:31 am »
Here is second screenshot

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #6 on: March 13, 2020, 10:41:50 am »
its a simple JS triggered form submit .. nothing complex

so check if the JS is working, if the form will submit when halted by the debug etc etc
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #7 on: March 14, 2020, 08:37:21 am »
This is the error showing when it diverts to home page when submitted. Does this help to show where to fix or what is causing this problem?

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #8 on: March 14, 2020, 10:59:37 am »
have u tried the basic stuff like using the base template Protostar or beez?

seeing a load time of nearly 6 seconds and a payload of +6MB would be ringing alarm bells for me
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #9 on: March 14, 2020, 23:03:39 pm »
Yes that was the first thing I did still divert to home page.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #10 on: March 15, 2020, 10:21:20 am »
Out of ideas -- needs some live site investigation
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

jjk

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 3656
  • using Matomo instead of Google Analytics
Re: Cart not diverting to PayPal redirect to home page
« Reply #11 on: March 15, 2020, 13:39:23 pm »
Did you try already to unpublish your jch-optimize and purge all it's cached pages?
Non-English Shops: Are your language files up to date?
http://virtuemart.net/community/translations

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #12 on: March 15, 2020, 21:16:31 pm »
I have tried un-publishing all extensions that could conflict with normal site running including jch-optimize and no difference. Also prior to change of hosting all extensions like jch were already installed and the site was working fine.

Please let me know if you require to Admin I can send password details? 

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9731
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.6.8
Re: Cart not diverting to PayPal redirect to home page
« Reply #13 on: March 15, 2020, 23:10:28 pm »
Changed host?

Didn't see that bit .. well .. worked before - changed hosts - stopped working - everyone else's on the planet is working - conclusion?
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

PaulLye

  • Beginner
  • *
  • Posts: 12
  • A beginner
Re: Cart not diverting to PayPal redirect to home page
« Reply #14 on: March 15, 2020, 23:27:38 pm »
I should have clarified a bit more, I didn't change hosting companies I change the type of hosting platform. I went from a VPS server to a shared server, I asked my the hosting company to check errors and their reply was no hosting errors but errors pointing to VirtueMart. Hence why I am here!