php - How to remove backslash on json_encode() function? -


How to remove (\) backslash on a string? For example: & lt ;? When using php $ str = "$ (\" # output \ "), echo json_encode () ?

) .append (\" & lt; p & gt; This is an exam!! & Lt; / p & gt; \ ")"; Echo json_encode ($ str); ? & Gt;

Note: When you explain $ str, there will be no problem ... but when you json_encode () , (\) < / Code> backslash will appear.

Is there any way to solve this? Thank you.

json_encode ($ response, JSON_UNESCAPED_SLASHES);

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

c# - Using Vici cool Storage with monodroid -

python - referencing a variable in another function? -