In addition, it is necessary to analyze a node and locate the Node path at a level. The biggest benefit of JSON is that you can easily call all the members of an object by declaring the data string as an object. It is also convenient to use JavaScript directly on the client. Program The data string generated by the client.
Anyone who uses ASP knows that ASP can use two types of script engines: VBScript and JScript. I didn't even know JScript when I first learned it. If I knew it, I don't think it is necessary for me to use JScript to convert JSON data so that I can use it in VBScript. Fortunately, the two script engines have their own advantages and disadvantages, and I have been using VBScript for more than two years. Although I am not strong enough, I am used to some of the following methods, formed your ownCodeOutput specification.
JSON officially written class files are quite convenient. You can flexibly define and output the desired JSON data format. I sorted out the official class files and changed them to a convenient format!
The URL of the adjusted JSON file:
Source code of asp json files
Code example:
1. Create a JSON objectCopy codeThe Code is as follows: Set cnodejson = new json_cls
Cnodejson. quotedvars = false' whether the object name is enclosed by quotation marks
Cnodejson ("ID") = 1
Cnodejson ("name") = "cloud. L"
Cnodejson ("blogname") = "cloud. l blog"
Set cnodejson = nothing
2. Create another object in the objectCopy codeThe Code is as follows: Set cnodejson = new json_cls
Cnodejson. quotedvars = false' whether the object name is enclosed by quotation marks
Cnodejson ("ID") = 1
Cnodejson ("name") = "cloud. L"
Cnodejson ("blogname") = "cloud. l blog"
Set cnodejson ("sitelist") = new json_cls
Cnodejson ("sitelist") ("blog") = "http://www.jb51.net"
Cnodejson ("sitelist") ("csdn") = "http://hi.csdn.net/lingyun410"
Set cnodejson = nothing