Permalink
Browse files

add query parameter checking and display

  • Loading branch information...
1 parent 4c41712 commit 667cc5c865056f1ef73098c8c3cdbd0268b30bd7 @imrehg committed Mar 1, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 web.js
View
@@ -30,8 +30,10 @@ app.get('/test', function(request, response) {
});
app.post('/location', function(request, response) {
+ var url_parts = url.parse(request.url, true);
+ var query = url_parts.query;
var data = request.body;
- socket.sockets.send(JSON.stringify(data));
+ socket.sockets.send("Data:"+JSON.stringify(data)+" Params:"+JSON.stringify(query));
response.send({result: 'okay'});
});

0 comments on commit 667cc5c

Please sign in to comment.