Blank page after returning from payment processor

  • Posts: 79
  • Thank you received: 2
5 years 5 months ago #299032

-- HikaShop version -- : 3.5.1
-- Joomla version -- : 3.8.13
-- PHP version -- : 7.2

Hello,

I have a problem with a blank page after returning from mollie (iDeal).
When returning to hikashop we end up with a blank page. JD iDeal has redirects to articles in a menu. Which are setup correctly.
When returning with the status "Canceled" or "Failed" we end up being redirected to the right article page. But when we return with a status "Confirmed" (paid), we end up on a blank page.
I have talked to the developer and we came up with the following.
This happens with the guest checkout. Where we think it goes wrong is here:

if(empty($order) || hikashop_loadUser(false) != $order->order_user_id)
   return false;
Since the guest user doesnt have an an account, it also doesnt have a user_id.
This happens when hikashop is set to "legacy checkout = yes". When we have "legacy checkout = no" we have the following problem. The text from the "after end" will show (see attachment). But will not redirect.

Also the after_end will have the option to see the order, which once you click that will goto login page. The guest user has no account, so thats a problem too. I know how to change the after_end view to not show that link. So could solve that problem.
Is there a way to make the redirect work?

Attachments:

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

  • Posts: 81361
  • Thank you received: 13036
  • MODERATOR
5 years 5 months ago #299039

Hi,

1. There is indeed a glitch with the after_end and the old chekcout for guest users.
You can add the code:

if($this->config->get('checkout_legacy', 0)) {
			return parent::after_end();
		}
after the line:
public function after_end() {
in the file components/com_hikashop/controllers/checkout.php in order to fix the issue with the line of code you're talking about.
We'll add that patch on our end.

2. The link there is working in such case for us. If the link is not working in your case and goes to a login page, this indicates that the URL there is missing the parameter order_token which allows the guest user to access his order page thanks to a secret token.
I suppose that this comes from a view override of the after_end view file in your template or if it's not a view override, you have an old version of HikaShop which doesn't have the patch with the order_token. In that case, updating would fix the problem.

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

  • Posts: 79
  • Thank you received: 2
5 years 5 months ago #299154

That code worked perfect to get to the after_end file.
The redirect from the plugin however does not work yet.

I talked again to the developer of JD iDeal and he told me in order for the redirect to work he kooks in to the "onHikashopAfterDisplayView" which apparently is not used with guest checkout.

Attachments:

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

  • Posts: 81361
  • Thank you received: 13036
  • MODERATOR
5 years 5 months ago #299156

Hi,

Well, I would need more details than just

kooks in to the "onHikashopAfterDisplayView"

because onHikashopAfterDisplayView is called before every view being displayed by HikaShop and the "hook" could be done in many ways.
Could you see with the developer if he could provide more details on the issue ?
And you confirm that we're still talking about the legacy mode ?

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

  • Posts: 79
  • Thank you received: 2
5 years 5 months ago #299223

Nicolas,

The developer of JD iDeal is going to contact you.

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

  • Posts: 222
  • Thank you received: 26
  • Hikaserial Subscription Hikashop Business
2 years 2 months ago #338234

Hi,
I have this problem with hs 4.4.4, I've made the update to 4.4.5 same problem (php 7.4) .
I use a plugin made by euplatesc.ro, to process the payment.
This is the url that I get redirected after I make the payment
/index.php?option=com_hikashop&ctrl=checkout&task=after_end&order_id=246&Itemid=275
And this is what I see, a blank page:


This can be a problem from the payment plugin?

Attachments:

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

  • Posts: 81361
  • Thank you received: 13036
  • MODERATOR
2 years 2 months ago #338237

Hi,

It's probably coming from the template not displaying the system messages:
www.hikashop.com/support/documentation/6...issues.html#messages
If you can, try to test with the default template of Joomla, and you should see the messages on that same page, confirming that it comes from the template.

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

Time to create page: 0.095 seconds
Powered by Kunena Forum