332650090 发表于 2020-9-25 17:32:52

JSON取值问题

请教大侠,JSON怎么取出下面文本的地址:

{"片名": "以家人之名", "集数": "全46集", "类型": "/伦理/喜剧/偶像", "年代": "2020", "地区": "大陆", "导演": "丁梓光", "演员": "谭松韵 宋威龙 张新成 涂松岩 张晞临 孙铱 何瑞贤 安戈 ", "影片简介": "该剧讲述了3个原生家庭有缺失的孩子组成了一个非血缘关系的家庭,兄妹三人彼此扶持成长,逐渐治愈了内心的伤,与过去的自己和解,成为了更好的人。", "选集": ["http://www.mgtv.com/b/333900/9578912.html", "http://www.mgtv.com/b/333900/9578925.html", "http://www.mgtv.com/b/333900/9589845.html", "http://www.mgtv.com/b/333900/9589868.html", "http://www.mgtv.com/b/333900/9599379.html", "http://www.mgtv.com/b/333900/9599455.html", "http://www.mgtv.com/b/333900/9608463.html", "http://www.mgtv.com/b/333900/9608488.html", "http://www.mgtv.com/b/333900/9617493.html", "http://www.mgtv.com/b/333900/9624745.html", "http://www.mgtv.com/b/333900/9630948.html", "http://www.mgtv.com/b/333900/9630963.html", "http://www.mgtv.com/b/333900/9638581.html", "http://www.mgtv.com/b/333900/9638597.html", "http://www.mgtv.com/b/333900/9656579.html", "http://www.mgtv.com/b/333900/9656597.html", "http://www.mgtv.com/b/333900/9665943.html", "http://www.mgtv.com/b/333900/9665950.html", "http://www.mgtv.com/b/333900/9674132.html", "http://www.mgtv.com/b/333900/9680085.html", "http://www.mgtv.com/b/333900/9685771.html", "http://www.mgtv.com/b/333900/9685809.html", "http://www.mgtv.com/b/333900/9691773.html", "http://www.mgtv.com/b/333900/9691827.html", "http://www.mgtv.com/b/333900/9698188.html", "http://www.mgtv.com/b/333900/9698229.html", "http://www.mgtv.com/b/333900/9704565.html", "http://www.mgtv.com/b/333900/9704580.html", "http://www.mgtv.com/b/333900/9710584.html", "http://www.mgtv.com/b/333900/9710611.html", "http://www.mgtv.com/b/333900/9716132.html", "http://www.mgtv.com/b/333900/9720947.html", "http://www.mgtv.com/b/333900/9725194.html", "http://www.mgtv.com/b/333900/9725234.html", "http://www.mgtv.com/b/333900/9731738.html", "http://www.mgtv.com/b/333900/9731708.html", "http://www.mgtv.com/b/333900/9738200.html", "http://www.mgtv.com/b/333900/9738227.html", "http://www.mgtv.com/b/333900/9744261.html", "http://www.mgtv.com/b/333900/9744289.html", "http://www.mgtv.com/b/333900/9750616.html", "http://www.mgtv.com/b/333900/9750622.html", "http://www.mgtv.com/b/333900/9757681.html", "http://www.mgtv.com/b/333900/9762162.html", "http://www.mgtv.com/b/333900/9767204.html", "http://www.mgtv.com/b/333900/9767253.html"], "反馈": "QQ113635321"}

独坐英雄冢 发表于 2020-9-25 17:32:53

   '用JSON操作类库
      变量 JSON 为 对象
        变量 JSON1 为 对象
        变量 i 为 整数型=0
        JSON=JSON操作1.解析(编辑框1.内容)
        JSON1=JSON操作1.取数组(JSON,"选集")
        判断循环首 i<JSON操作1.取数组内成员数(JSON1)
                弹出提示(JSON操作1.取数组内文本值(JSON1,i))
                i=i+1
        判断循环尾

jcstudio 发表于 2020-9-25 18:40:42

取文本很多方法,为什么非要JSON呢,如正则表达式或循环取指定文本等

332650090 发表于 2020-9-25 19:21:29

jcstudio 发表于 2020-9-25 18:40
取文本很多方法,为什么非要JSON呢,如正则表达式或循环取指定文本等

我就觉得的奇怪,明明就是JSON,为什么就取不出来了{:4_102:}

332650090 发表于 2020-9-25 19:23:48

jcstudio 发表于 2020-9-25 18:40
取文本很多方法,为什么非要JSON呢,如正则表达式或循环取指定文本等

用正则还是很简单的:http(.*?)html

eruyivip 发表于 2020-9-26 00:53:49

JSON取值

我来逛逛 发表于 2020-9-26 09:46:05

多简单啊,用-取指定文本()这样就返回带http的文本组

yudave 发表于 2020-9-26 11:26:57

就来看看了

eruyivip 发表于 2020-10-1 04:59:59

取值问题

duanyijun 发表于 2020-10-2 06:45:36

看帖必回真君子
页: [1] 2
查看完整版本: JSON取值问题