0){ include_once("credential.php"); $mongoip = $credential_arr['ip']; $m = new Mongo($mongoip); $db = $m->$credential_arr['db']; $collection = $db->$credential_arr['coll_comment']; $srcdbobj = json_decode($data,true); $collection->insert($srcdbobj); $m->close(); unset($m); unset($db); unset($collection); echo "
Added successfully"; }else{ echo $prompt["Fail"]; } ?>