![JSON.parse solutions to string parsing errors_javascript skills](http://files.jb51.net/upload/201007/20100708153719457.jpg)
After investigation, it turns out that the format of json data is very strict, and the attribute name must be enclosed in double quotes "".
var a=JSON.parse('{ "a":"aaaaa"}');//Correct
var a=JSON.parse("{'a':'aaaaa'}");//Wrong
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn