I have an installation of OpenCart v 1.5.6. I'm getting the following error when attempting to login for checkout (see attachment for full details):
SyntaxError: JSON.parse: unexpected character
It's relating to catalog/controller/checkout/login.php on line 54 and 60 which as far as I can tell is kicking up a stink about the posted values for email and password.
I've never experienced this before in any installation so I'm not sure why it's happening. Any ideas?
Cheers
I figured out the fix for this issue. To cut a long story short, the issue is that the checkout.tpl file in the default theme for opencart 1.5.6 has a bug in the login ajax function.
On line 137 in /catalog/view/theme/default/template/checkout/checkout.tpl I changed the code from this
to this
This fixed the issue for me.
I sincerely hope this helps somebody else as this issue caused me a few hours of pulling my hair out, swearing, yada yada!
On line 137 in /catalog/view/theme/default/template/checkout/checkout.tpl I changed the code from this
Code: Select all
data: $('#checkout #login :input'),
Code: Select all
data: $('#checkout #login input[type=\'text\'], #checkout #login input[type=\'password\']'),
I sincerely hope this helps somebody else as this issue caused me a few hours of pulling my hair out, swearing, yada yada!
Hey well done!
I have never come across that bug but thanks to you we have a solution - you may wish to edit your opening title to include [SOLVED] to help others find it more easily, and I am linking to this thread from the old one you also posted in regarding the same issue.
Cheers,
Stokey
I have never come across that bug but thanks to you we have a solution - you may wish to edit your opening title to include [SOLVED] to help others find it more easily, and I am linking to this thread from the old one you also posted in regarding the same issue.
Cheers,
Stokey
Stokey
Who is online
Users browsing this forum: No registered users and 312 guests