我如何从json中删除双引号

本文关键字:删除 json | 更新日期: 2023-09-27 18:07:37

我有一个json字符串如下。

"{
  "stepno": 1,
  "content": "dddd",
  "icon": "plug icon",
  "header": "Uptime Guarantee",
  "headcolor": "ffffff",
  "tagline": "Check out our plug-in marketplace",
  "taglinecolor": "ffffff",
  "isActive": true
}"

我想从像follow这样的属性中删除双引号

"{
stepno: 1,
content:'', 
icon:'plug icon',  
header:'Uptime Guarantee',
headcolor:'ffffff', 
tagline:'Check out our plug-in marketplace',
taglinecolor:'ffffff',
isActive:true
}"

我该怎么做?

我如何从json中删除双引号

可以使用mysql_real_escape_string()。它将删除引号