function processPost(req, res) {
  var body = '';  //anything concatenated to this will be 'toStringed'
  req.on('data', function(data) {
    body += data;
  });
  req.on('end', function() {
    res.write(getDay(JSON.parse(body)) + '\n'); //status is 200 by default
    res.end();
  });
}
// a function to process the POSTED data and provide a response
a function to process the POSTED data and provide a response
a function to process the POSTED data and provide a response
function processPost(req, res) {
  var body = '';  
  req.on('data', function(data) {
    body += data;
  });
  req.on('end', function() {
    res.write(getDay(JSON.parse(body)) + '\n'); 
    res.end();
  });
}
function processPost ( req , res ) { var body = '' ; req . on ( 'data' , function ( data ) { body += data ; } ) ; req . on ( 'end' , function ( ) { res . write ( getDay ( JSON . parse ( body ) ) + '\n' ) ; res . end ( ) ; } ) ; }
a function to process the POSTED data and provide a response
a function to process the POSTED data and provide a response
//anything concatenated to this will be 'toStringed' //status is 200 by default