Removing slashes which escape quotes inside strings
Publish PHP Package / docker (push) Successful in 5s
Details
Publish PHP Package / docker (push) Successful in 5s
Details
This commit is contained in:
parent
bf41349ad0
commit
8cbbdd94cb
|
@ -249,7 +249,9 @@ class jzonParser
|
|||
{
|
||||
$end = $this->c;
|
||||
++$this->c;
|
||||
return substr($this->in, $start, $end - $start);
|
||||
$str = substr($this->in, $start, $end - $start);
|
||||
//let's remove escape slashes before "
|
||||
return str_replace('\\"', '"', $str);
|
||||
}
|
||||
$prev = $this->in[$this->c];
|
||||
++$this->c;
|
||||
|
@ -351,6 +353,7 @@ function jzon_parse($str)
|
|||
else
|
||||
{
|
||||
$p = new jzonParser($str);
|
||||
return $p->parse();
|
||||
$res = $p->parse();
|
||||
return $res;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue