[SOLUCIONADO] unexpected character at line 1 column 1 of the JSON data

Iniciado por graphixx, Junio 09, 2016, 09:27:40 PM

Tema anterior - Siguiente tema

0 Miembros y 1 Visitante están viendo este tema.

Junio 09, 2016, 09:27:40 PM Ultima modificación: Junio 09, 2016, 10:21:58 PM por Gabriela


Solucion al error JSON.parse

Firefox:
SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data



Chrome:
Uncaught SyntaxError: Unexpected token < in JSON at position 0



El error en mi caso se debía a que en la tabla de la base de datos que estaba insertando el registro, el ID que era clave primaria no estaba a AUTO INCREMENT.

Puede ser causado también si indicas una clave como NOT NULL y no es el usuario el que la llena si no el script y la estas enviando vacía.

Undertip: You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login
Mi Blog Personal
You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login