X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=encode.php;h=a395a10ef3e8558dc23b7a11214e811741b7d89d;hb=dfb559a8ce4e04d8e5f27f8587141e97f9af1a59;hp=381e68169539a9c4e13d4e97654947170db20418;hpb=5b223129ade45127f3945a354f8b2a56799f472c;p=wfpl.git diff --git a/encode.php b/encode.php index 381e681..a395a10 100644 --- a/encode.php +++ b/encode.php @@ -32,6 +32,10 @@ function enc_jsdq($str) { return $str; } +function enc_json($str) { + return json_encode($str); +} + # encode for putting within double-quotes in SQL function enc_sql($str) { $str = str_replace("\\", "\\\\", $str);