diff --git a/sendNotif.php b/sendNotif.php index 30be0c6b786861397f8a35ed13f4dc80b30dfd7c..8b5f5888261f85c6c11bb3ee86c41df3f32b2019 100755 --- a/sendNotif.php +++ b/sendNotif.php @@ -43,14 +43,14 @@ class FirebaseNotif "id" => $id ] ]; - echo json_encode($vars); + echo json_encode($vars, JSON_UNESCAPED_SLASHES); // $cat = $_POST["kategori"]; // if ($cat == "pengumuman" ) { $vars["notification"]["click_action"] = "mainActivity"; //testing // $vars["data"] = array("id" => $_POST["id"]); // } - curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($vars)); //Post Fields + curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($vars, JSON_UNESCAPED_SLASHES)); //Post Fields curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $headers = [ 'Authorization: key=AIzaSyDhcKAiH6wOm8QhHLnYZzrri8SyZZtcoe4',