2015-06-16 43 views
0

以下編碼的JSON引起的JSON錯誤而編碼數據

解析錯誤的錯誤在第9行:... 0.0.1" ,「管理員(藍色)改變 ----- ----------------- ^期待'STRING','NUMBER','NULL','TRUE','FALSE','{','['

我是新來的JSON因此,誰能幫我解決這個錯誤

{ 
     "draw": 2, 
     "recordsTotal": 1739, 
     "recordsFiltered": 1739, 
     "data": [ 
      [ 
       "22-Apr-15 03:37 pm", 
       "Task", 
       "127.0.0.1", 
       "Admin (Blue) Changed Plan to Task On:<\/b> 22-04-2015 03:37:51 PM 
    CURRENT-Task Title: admin to employeee NEW-Task Title: admin to employeeesdfsd, CURRENT-Description: admin to employeeeadmin to employeeeadmin to employeee, NEW-Description: admin to employeeeadmin to employeeeadfdmin to employeee, CURRENT-Priority: Medium, NEW-Task Priority: Low, CURRENT-Size: Small, NEW-Size: Big, CURRENT-Status: Last, NEW-Task Status: S, CURRENT-Background Color: Empty, NEW-Background Color: #b83939, CURRENT-Text Color: Empty, NEW-Text Color: #faf5f5, CURRENT-Assigned To: Raja(Admin), NEW-Assigned To: Raja(Admin), Vimala(Bharath), CURRENT-Completion Date: 16-04-2015, NEW-Completion Date: 18-04-2015" 
      ], 
      [ 
       "22-Apr-15 03:38 pm", 
       "Task", 
       "127.0.0.1", 
       "Bharath (Task) Task Edited On:<\/b> 22-04-2015 03:38:41 PM 
    OLD-Task Title:admin to employeee, NEW-Task Title:admin to employeeesdfsd, OLD-Description:admin to employeeeadmin to employeeeadmin to employeee NEW-Description:admin to employeeeadmin to employeeeadfdmin to employeee, OLD-Priority:Medium, NEW-:PriorityLow, OLD-Size:Small, NEW-Size:Big, OLD-Status:S, NEW-Status:S, OLD-Assigned To:Raja(Admin), NEW-Assigned To:Raja(Admin), Vimala(Bharath), OLD-Completion Date:16-Apr-2015, NEW-Completion Date:18-Apr-2015" 
      ], 
      [ 
       "22-Apr-15 03:41 pm", 
       "Plan", 
       "127.0.0.1", 
       "Bharath (Task) Plan Assigned On:<\/b> 22-04-2015 03:41:25 PM 
    Plan Title:sdfs, Assigned To: Manickam(Admin), Priority: Medium, Size: Small, Completion Date: 20-04-2015" 
      ], 
      [ 
       "22-Apr-15 03:41 pm", 
       "Plan", 
       "127.0.0.1", 
       "Bharath (Task) Plan Assigned On:<\/b> 22-04-2015 03:41:57 PM 
    Plan Title:erwe, Assigned To: Admin, Priority: High, Size: Medium, Completion Date: 24-04-2015" 
      ], 
      [ 
       "22-Apr-15 04:13 pm", 
       "Plan", 
       "127.0.0.1", 
       "Admin (Blue) Plan Assigned On:<\/b> 22-04-2015 04:13:46 PM 
    Plan Title:dfg, Assigned To: Admin, Priority: Medium, Size: Medium, Completion Date: 09-04-2015" 
      ], 
      [ 
       "22-Apr-15 04:22 pm", 
       "Plan", 
       "127.0.0.1", 
       "Admin (Blue) Plan Completed On:<\/b> 22-04-2015 04:22:24 PM 
    Plan Title:sdf" 
      ], 
      [ 
       "22-Apr-15 04:22 pm", 
       "Plan", 
       "127.0.0.1", 
       "Admin (Blue) Plan Uncompleted On:<\/b> 22-04-2015 04:22:34 PM 
    Plan Title:activity assigned" 
      ], 
      [ 
       "22-Apr-15 04:22 pm", 
       "Plan", 
       "127.0.0.1", 
       "Admin (Blue) Plan Uncompleted On:<\/b> 22-04-2015 04:22:35 PM 
    Plan Title:activity assigned" 
      ], 
      [ 
       "22-Apr-15 04:26 pm", 
       "Task", 
       "127.0.0.1", 
       "Admin (Blue) Edition Awaiting Approval On:<\/b> 22-04-2015 04:26:36 PM 
    Task Title: activity assigned, CURRENT-Description: sdfs, NEW-Description: sdfswerwe" 
      ], 
      [ 
       "22-Apr-15 04:26 pm", 
       "Plan", 
       "127.0.0.1", 
       "Admin (Blue) Plan Edition Changes Undone On:<\/b> 22-04-2015 04:26:52 PM 
    Plan Title:activity assigned, CURRENT-Description:sdfs NEW-Description:sdfswerwe" 
      ] 
     ] 
    } 

回答

1

你生你的字符串換行符。第一個是在

"Admin (Blue) Changed Plan to Task On:<\/b> 22-04-2015 03:37:51 PM

末你不能這樣做,在JSON。如果你想在字符串中換行,使用\n


注意:如果您是JSON的新手,http://jsonlint.com/是您的朋友。儘管如此,您在這種情況下遇到的錯誤並不是很豐富。