common.captcha.js
357 Bytes
module.exports=function(app) {
app.get("/captcha", "captcha_create", function (captcha, req, res){
res.writeHead(200, {
'Content-Type': 'image/png'
});
res.end(captcha);
});
app.post("/checkCaptchaImg", "captcha_checkCaptchaImg", function (captcha, req, res){
return res.json(captcha);
});
}