Guest PayPal Checkout

  • Posts: 27
  • Thank you received: 2
  • Hikashop Business
1 week 4 days ago #368944

-- HikaShop version -- : 6.1.0
-- Joomla version -- : 5.3.4
-- PHP version -- : 8.2.29
-- Browser(s) name and version -- : Safari

Hi Guys,

I have a strange problem that has been going on for some time and I've not been able to solve it.

The problem is with a guest checking out with PayPal. This issue occurs on a regular basis but if the customer registers and then places an order PayPal checkout seems to work.

One customer said:
When I went to checkout I selected PayPal but it never redirected. The whole screen went blank with an error message for a developer. Never saw anything PayPal related.
This customer is using Safari on an iPhone 15.

Cheers,
Jason.

Please Log in or Create an account to join the conversation.

  • Posts: 84545
  • Thank you received: 13747
  • MODERATOR
1 week 4 days ago #368945

Hi,

It would have been great if the customer could have provided the "error message for a developer".
If there is a fatal error during the order creation process (which can come from a plugin, a mass action, some customization, etc), it could result in what is described and the error message would help understand what is going on.
I see two things:
- Supposing that it is a PHP fatal error during the order creation process, the error message can be logged in the PHP error log, provided that your hosting has your server configured for it (which is usually the case). So, checking the PHP error log for "fatal error" messages and providing that message to us should allow us to tell you what to do.
- It's possible that it isn't a PHP fatal error but just a blank popup. This is described in the PayPal Checkout documentation page:
www.hikashop.com/support/documentation/4...out-form.html#issues

Supposing that the buttons are displayed, if you click on the "PayPal" button and you don't get the PayPal payment popup, or you get a blank popup on top of the normal popup, it's likely you have a problem with the Cross Origin Opener Policy of your website. You need to configure your System - HTTP Headers plugin, via the Joomla plugins manager. In its Plugin tab, change its "Cross-Origin-Opener-Policy" setting to "same-origin-allow-popups"

So I would recommend checking the settings of this plugin.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 2
  • Hikashop Business
1 week 4 days ago #368947

Hi Nicolas,

Yes, would be nice to have a screen shot of the error. Unfortunately, I'm unlikely to see that.

Attached is a screenshot of my plugin.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 84545
  • Thank you received: 13747
  • MODERATOR
1 week 4 days ago #368949

Hi,

The way you configured this plugin will potentially generate these blank popups with PayPal Checkout due to the way PayPal Checkout works.
I would recommend setting the "Cross-Origin-Opener-Policy" setting to "same-origin-allow-popups" as explained in my previous message.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 2
  • Hikashop Business
1 week 3 days ago #368964

Nicolas, it is set to "same-origin-allow-popups". That's why I posted the picture just in case another setting needed changing.

Please Log in or Create an account to join the conversation.

  • Posts: 84545
  • Thank you received: 13747
  • MODERATOR
1 week 3 days ago #368967

Hi,

My bad, it seems I was tired yesterday. I somehow thought it wasn't when I glanced at your screenshot yesterday.
Then, it's good and it doesn't come from this.
I would recommend checking the PHP error log for fatal errors. You might need to contact your hosting for that.

Please Log in or Create an account to join the conversation.

  • Posts: 27
  • Thank you received: 2
  • Hikashop Business
1 week 2 days ago #368979

All good Nicolas.

Looking at my hosting (SiteGround) the error log shows as per the attached. I'm not sure this is the right information as it only covers the last couple of days. Even SiteGround says it should be the last 300 errors.

I've been in touch with Siteground.

The log file in my public folder was from 2023 to 2024. Siteground has deleted the file so a new one will be created when errors are logged. I tried to simulate a guest order but PayPal seems to work fine for me on the MacBook and iPhone. I guess I just need to wait until the next problems to be logged.

Attachments:
Last edit: 1 week 2 days ago by Precisionaeroproducts.

Please Log in or Create an account to join the conversation.

  • Posts: 84545
  • Thank you received: 13747
  • MODERATOR
1 week 2 days ago #368982

Hi,

This is the access log of the web server, not the error log of PHP.
So, you won't find the information there.

The PHP error log can be configured in the php.ini file :
stackify.com/php-error-logs-guide/
If you have access to the php.ini, you might have to configure it yourself.

If the problem happened only once and it works for other orders, then it probably isn't a PHP error.
It could be the "invoice already used" issue:

If you get an error with the text "invoice id already used" it means that you already used your PayPal account with another ecommerce website and it used the same order ids as HikaShop. You can either modify the auto_increment value of the hikashop_order table in your PHPMyAdmin to start order ids to a big number which hasn't been used by your other website, or you can navigate to www.paypal.com/businessmanage/preferences/payments and under "Block accidental payments" select "No, allow multiple payments per invoice ID"

It's hard to say, without the customer providing more information and you not able to reproduce the issue.

Please Log in or Create an account to join the conversation.

Time to create page: 0.080 seconds
Powered by Kunena Forum