Post by stevedesign » Sat Jul 02, 2011 2:32 am

Welcome i have error: SyntaxError: JSON.parse: unexpected character , I am from PoLAND and I use polish language which i translated from English. When I add polish language, I have error, choicing Flat Rate in Checkout >> Delivery ...I dont now why, because in English (language) when i choice in shop everything is ok in Polish not ;/ sory my English ist not good < Can someone help me ?

Newbie

Posts

Joined
Sat Jul 02, 2011 2:27 am

Post by minijus » Fri Jul 22, 2011 10:22 pm

Hello,
I have website in 6 languages and I experience the same error in 4 langauges (Duetsch, French, Russian and Spanish) while English and Lithuanian works perfect.
Currently I am working on this issue but nothing comes to my mind. Does anybody else experienced the same issue ? Is there a solution for this error ?

Newbie

Posts

Joined
Tue Jul 12, 2011 12:21 am

Post by Daniel » Fri Jul 22, 2011 10:47 pm

does your servers have the php json extension installed? if not it will be using the json functions i created.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by minijus » Sat Jul 23, 2011 4:50 pm

Daniel wrote:does your servers have the php json extension installed? if not it will be using the json functions i created.
Yes,
my server support json:
json support enabled
json version 1.2.1

Newbie

Posts

Joined
Tue Jul 12, 2011 12:21 am

Post by minijus » Tue Jul 26, 2011 7:33 pm

any ideas where I could start looking for problem?

Newbie

Posts

Joined
Tue Jul 12, 2011 12:21 am

Post by Daniel » Tue Jul 26, 2011 9:59 pm

which language pack did you use?

also if you did the translation your self which php editor did you use?

if its a .net editor sometimes Microsoft adds stuff to the header of files.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by ripper » Tue Jul 26, 2011 11:12 pm

I have the same problem. Even when I chose English it's still the same error. How can I find if I have json installed? I read that from PHP 5.2 it's automatically in the package. I have it on local.

Thx

New member

Posts

Joined
Wed Jul 06, 2011 4:37 am

Post by minijus » Wed Jul 27, 2011 12:08 am

Daniel wrote:which language pack did you use?

also if you did the translation your self which php editor did you use?

if its a .net editor sometimes Microsoft adds stuff to the header of files.
I use 5 additional lang packs and all of them are downloaded from opencart.com website. Is there any way I could check them?

Newbie

Posts

Joined
Tue Jul 12, 2011 12:21 am

Post by Daniel » Wed Jul 27, 2011 7:59 pm

but which ones? which ones is this happening with.

any idea which characters are causing the problem?

try typing in your alaphabet and when you come to the one that stops working let me know.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by ripper » Wed Jul 27, 2011 8:05 pm

Daniel wrote:but which ones? which ones is this happening with.

any idea which characters are causing the problem?

try typing in your alaphabet and when you come to the one that stops working let me know.
Hi,
I have the same problem with English too. Do you have any idea?

New member

Posts

Joined
Wed Jul 06, 2011 4:37 am

Post by Daniel » Wed Jul 27, 2011 8:55 pm

ripper wrote:
Daniel wrote:but which ones? which ones is this happening with.

any idea which characters are causing the problem?

try typing in your alaphabet and when you come to the one that stops working let me know.
Hi,
I have the same problem with English too. Do you have any idea?

which character?

is it when you use " or ' or something?

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by Daniel » Wed Jul 27, 2011 9:02 pm

ripper wrote:
Daniel wrote:but which ones? which ones is this happening with.

any idea which characters are causing the problem?

try typing in your alaphabet and when you come to the one that stops working let me know.
Hi,
I have the same problem with English too. Do you have any idea?

ok pm me access to your4 site and tell me how to produce the problem.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by ripper » Wed Jul 27, 2011 11:18 pm

Daniel wrote:
ripper wrote:
Daniel wrote:but which ones? which ones is this happening with.

any idea which characters are causing the problem?

try typing in your alaphabet and when you come to the one that stops working let me know.
Hi,
I have the same problem with English too. Do you have any idea?

ok pm me access to your4 site and tell me how to produce the problem.
I have it in VmWare for testing. It doesn't write any character. :(

New member

Posts

Joined
Wed Jul 06, 2011 4:37 am

Post by pminne » Tue Aug 02, 2011 9:44 pm

Having this problem as well, and looking for a way to solve it, I noticed this "$json = array();" in /catalog/controller/checkout/confirm.php (around line 50).
This seems a bit strange since there may be values assigned already to $json. Moving this declaration to the top doesn't solve the issue of the JSON error, but I thought it's worth mentioning it whatsoever.

Newbie

Posts

Joined
Tue Aug 02, 2011 9:15 pm

Post by Daniel » Wed Aug 03, 2011 3:51 am

could it be a missing file?

ok some one who is having this problem please pm me their login ftp details.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by jisuanji8509 » Sat Aug 13, 2011 2:29 pm

i have the same issue. i test one of my module is normal when i upload to server,it tips "SyntaxError: JSON.parse: unexpected character". i don't know why?

Newbie

Posts

Joined
Sat Dec 18, 2010 11:59 pm

Post by Daniel » Mon Aug 15, 2011 2:05 am

just tested this on someone's site and it looks like the problem happens when no shipping options are available.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by Daniel » Mon Aug 15, 2011 2:12 am

ok found out this person could not load a require model on a custom payment method.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by eddshouse » Mon Aug 15, 2011 11:27 pm

hi, im having the same error, tryng to checkout out using paypal standard and weight based shipping and it comes up. im using th latest build of opencart
thanks

Newbie

Posts

Joined
Mon Aug 15, 2011 11:24 pm

Post by Qphoria » Mon Aug 15, 2011 11:30 pm

Yea this error is non-specific and can happen at any step in the checkout, most notably the shipping and payment selection steps.
It can happen for a number of reasons
- Bug in the code, making it very difficult to debug
- Missing a file
- Unexpected data

I hope we can find a better way to report the actual php error back to ajax.

Image
Donate!|OpenCart Basics|GeoZones
Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am
Who is online

Users browsing this forum: No registered users and 7 guests