What do you think?
Rate this book


284 pages, Paperback
First published November 29, 2012
class Cat {
function Cat() {
// rather than __construct
}
}
var initreq = require('./initreq.njs');
exports.serve = function(req, res) {
var pre = {};
initreq.initGET(req, pre, function() {
initreq.initPOST(req, pre, function() {
initreq.initCOOKIE(req, pre, function() {
initreq.initREQUEST(req, pre, function() {
initreq.initSESSION(req, pre, function() {
page(req, res, pre, function() {
var cookies = [];
for (var c in pre._COOKIE) {
cookies.push(c + '=' + pre._COOKIE[c]);
}
res.setHeader('Set-Cookie', cookies);
res.writeHead(200, {
'Content-Type': 'text/plain'
});
res.end(res.content);
});
});
});
});
});
});