Modify ↓
Ticket #6560 (closed bug: invalid)
Problem with getJSON
| Reported by: | gerardogup | Owned by: | |
|---|---|---|---|
| Priority: | Milestone: | 1.4.3 | |
| Component: | ajax | Version: | 1.4.2 |
| Keywords: | getJSON, json | Cc: | |
| Blocking: | Blocked by: |
Description
I have an script working perfectly with verion 1.3.2. This script uses getJSON function. Nevertheless, when I upgrade to 1.4.1 or 1.4.2, it does not work. Callback function never fires and when i track the error using $.ajax function, there is a parser error. This error says that i have an invalid JSON. This is not true because using 1.3.2 works fine. JSON structure has the next format... { variable1 : 'value1', variable2 : 'value2', variable3 : 'value3' } Thank you for your support. Gerardo
Change History
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.
Note: See
TracTickets for help on using
tickets.

That is not valid JSON, the variables and values need to be quoted with double quotes. See json.org for the syntax. If you need to parse invalid JSON, get the response as text and eval() it yourself.