Hii... I am working with angular2 and lua as my server. Angulajs post a json object to the lua server . At Server side , how can I write these JSON Object into a new json file. Is there any possible solution for this ?
in my angular component I used ,
let headers = new Headers({ 'Content-Type': 'application/json' });
let options = new RequestOptions({ headers : headers });
let body = JSON.stringify(this.Cost);
//var str = JSON.stringify();
var a ="hello";
//alert(body);
var res = this.http.post('http://192.168.0.100:80/login/savecost.lua',body)
.map(res => res.json());
how can I access these JSON object in LUA and save it into new json file ??
please help ..Thanks in advance ..!