Skip to main content

Stripe Checkout payment and error in SQL syntax

More
2 weeks 6 days ago #100000161 by jean-loup
-- url of the page with the problem -- : www.121time.com
-- HikaShop version -- : 6.6.0
-- Joomla version -- : 5.4.9
-- PHP version -- : 8.5.9
-- Browser(s) name and version -- : Safari 605.1
-- Error-message(debug-mod must be tuned on) -- : 1064
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')' at line 1

Hello

Just bought Hikashop Stripe Checkout Payment and payments are going through and are listed in Stripe dashboard, but I get this error page after it is done.

Can you help please? A confirmation page instead would be nice to get !

Thank you in advance

Jean-Loup

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

More
2 weeks 6 days ago #100000162 by nicolas
Hello Jean-Loup,

Thank you for the screenshot. The error "near ')' at line 1" comes from a database query with an empty list of values. We tested the Stripe Checkout plugin with HikaShop 6.6.0, both the return from Stripe and the payment notification. The order gets confirmed and the thank-you page shows without any error. The query that fails on your site most likely belongs to another extension that runs when the order is confirmed or when the thank-you page is displayed, so we need to see where it comes from.

Could you please:

1. In Joomla, go to System > Global Configuration > System, set "Debug System" to Yes, and in the Server tab set "Error Reporting" to Maximum.

2. Make a test payment again and send us a screenshot (or a copy) of the whole error page. With debug on, it shows the full SQL query and the list of files and functions that ran it, so we can tell which extension is involved. You can set both options back once you have it.

3. Tell us whether the orders paid this way end up in the "confirmed" status in HikaShop > Orders despite the error, and which version of HikaSerial you have installed, if any.

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

More
2 weeks 6 days ago - 2 weeks 6 days ago #100000169 by jean-loup
Hello Nicolas,

Just done and the message is below. 

The order has a status CREATED and not CONFIRMED despite the payment received. 
Hikaserial was just updated and You have the latest stable version of HikaSerial: 6.1.1

Thanks for your help... 

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 250

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 271

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274

Warning: Undefined array key "" in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274

Warning: Attempt to read property "sef" on null in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 250

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 271

Deprecated: Using null as an array offset is deprecated, use an empty string instead in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274

Warning: Undefined array key "" in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274

Warning: Attempt to read property "sef" on null in /home/clients/d53d54a5c29e90b4075f63181c97aaa5/web/plugins/system/languagefilter/src/Extension/LanguageFilter.php on line 274
Last edit: 2 weeks 6 days ago by jean-loup. Reason: format text better!

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

More
2 weeks 6 days ago #100000174 by nicolas
Thank you. The messages you copied are only notices from Joomla's own Language Filter plugin with PHP 8.5. They are harmless and are not what breaks the payment.

What we need is the "Call stack" table that Joomla adds under the SQL error when Debug System is on. Your site's template shows its own error page (the dark "1064" page), and that page hides this information. To get it:

1. Keep Debug System on, then go to System > Site Template Styles and click the star of Cassiopeia to make it the default template for a few minutes.

2. Make a test payment again. The error page will now show the SQL query and the "Call stack" below it. Copy the whole page (or take screenshots of all of it) and send it to us.

3. Set your own template back as the default and turn Debug System off.

Since the orders stay in "Created", the payment notification Stripe sends to your site most likely fails with the same error. You can check it in your Stripe dashboard, under Developers > Webhooks: open the endpoint that ends with "notif_payment=stripecheckout" and look at the latest event deliveries. If they failed, the response shown there is your site's error, and a copy of it helps us too. If there is no such endpoint at all, open the Stripe Checkout payment method in HikaShop > System > Payment methods and save it once: the plugin then registers the endpoint in Stripe by itself.

We tested the same setup (HikaShop 6.6.0, Stripe Checkout, HikaSerial 6.1.1, a product with a serial pack, PHP 8.5) and the order was confirmed and its serial assigned without any error, so the query that fails comes from something specific to your site, most likely another extension that runs when the order is confirmed. The call stack will tell us which one.

In the meantime, the payments are in your Stripe account: you can set the paid orders to "Confirmed" yourself in HikaShop > Orders, with the status dropdown of each order.

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

More
2 weeks 5 days ago #100000176 by jean-loup
So I duplicated my site in testing environment with testing stripe environment also. 
I downgraded to PHP 8.4 since falang made lots of errors with 8.5 despite the last falang version; and the error disappeared. But not sure it has an influence since messages are almost the same

With Cassiopea, I passed an order with testing cards numbers and I put the report from the site below in a file. Together with 3 print screens of the developers Stripe after the notif_payment=stripecheckout

Being not a professional IT, it start to be little bit complicated for me 😓
You will see also the different STRP plugin I have, almost all tested...

Thank you for your help Nicolas

JL

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

More
2 weeks 5 days ago #100000177 by jean-loup
BTW the info in the payment plugin I entered
Not a lot so far...

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

More
2 weeks 5 days ago #100000178 by nicolas
Hi,

Thank you, the call stack is exactly what we needed, and it shows the error comes from HikaShop itself. When Stripe sends the payment notification (and when you come back from the Stripe page, which goes to the same address), HikaShop first loads the names of the order statuses and, because Falang is installed on your site, looks for their Falang translations. On your site that list of statuses comes back empty, the translation query is then built with an empty list, and the database refuses it with the error 1064. The notification stops there, before the order is updated, which is why your paid orders stay in "created".

We reproduced it and corrected it. The correction is available on our end. Download the install package of HikaShop on our website and install it on yours in order to get the patch.

After that, make a test payment on your test copy: you should come back to the thank-you page and the order should switch to "confirmed". For the payments already made, you can set the orders to "Confirmed" in HikaShop > Orders. You can also resend the failed events from the webhook page of your Stripe dashboard, and HikaShop will then update those orders by itself.

If you still get an error page after the change, send us its call stack the same way and we will look at the next step.

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

More
2 weeks 5 days ago #100000179 by jean-loup
Sincerely sorry Nicolas, but probably not the answer we are waiting for!

Installed: com_hikashop_business_v6.6.0_2026-10-09_11-47-47

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

More
2 weeks 5 days ago #100000181 by jean-loup
Dear Nicolas, you found the solution, I sincerely apologise.
I installed HTProtect plugin and it comes from here.
Everything working well when disabled
Sincere apologies and than you for your efforts

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

More
2 weeks 5 days ago #100000182 by nicolas
Thank you for the new call stack. While the problem is fixed for you, we still look into the new call stack and made another fix.

The new correction is available on our end. Download the install package of HikaShop on our website and install it on yours in order to get the patch if necessary in the future, for you or someone else with the same issue.

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

More
2 weeks 5 days ago #100000184 by jean-loup
Thank you Nicolas, still fighting with HTProtect configuration in order to allow stripe payment to go through, since it is working like a charm when HTProtect is disabled but can't manage so far to find the solution in HTP parameters

But thanks again for the first class service !

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

More
2 weeks 5 days ago #100000186 by nicolas
The SQL error (1064, near ')' at line 1) comes from HikaShop's payment notification. When the translation plugin Falang is active, HikaShop reads the order status names to translate them, and when no status name is found it builds an invalid query. This should stop the error: the fix is in HikaShop's code and in the 6.6.0 release branch, so a new 6.6.0 build will include it. The build you have does not include it yet, so please update once the corrected build is available to you, and then test a Stripe payment.

About HTProtect: on a test site with the same Joomla version (5.4.9), HTProtect 2.7.17 with its protection shield written and real-time protection on, the Stripe return address and the payment notification went through without being blocked. HTProtect only blocks obvious attack strings in the address, such as script tags or path traversal. So its default rules alone do not stop the payment; if something is blocked, it comes from another HTProtect setting.

Could you tell us whether HTProtect's log of blocked requests shows 403 entries at the time of a failed payment and, if so, the address they show; the exact address your browser lands on after Stripe; and whether Backend access protection, Emergency offline or Joomla's debug option is turned on. With these we can pin down the block.

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

More
2 weeks 4 days ago #100000187 by jean-loup
Dear Nicolas

I re-installed my testing environment like the prod one from scratch, and updated Hikashop without modifying anything.
And it worked at the first payment test! 

Honestly you are incredible in matter of customer service... 24 hours to find a solution to an issue that required you to change twice Hikashop version in 24 hours... World class customer service!

Thank you for anything, I guess I won't touch any parameter of HTProtect since it is working well. I update now the live environment and will contact you in case of issues, but it shouldn't ;-)

Thank you again. Best regards

JL
The following user(s) said Thank You: nicolas

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

More
2 weeks 4 days ago #100000188 by jean-loup
I confirm that working like a charm in live environment just by updating Hikashop business.
So I won't investigate further about HTProtect since it's working!
Thank you again Nicolas.
The following user(s) said Thank You: nicolas

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

Time to create page: 0.144 seconds
Powered by Kunena Forum