404project 中文文档教程
node-404project
用于向位于 http://www.dshield.org/tools/404project.html 的“404 项目”报告 404 服务器错误的简单客户端。
Installation
npm install 404project
Usage
var express = require('express');
// the user id is usually a number, like 1234567
var myUserID='[Your ISC ID]';
var myKey='[Your Authentication Key]';
var reporter = require('404project').create(myUserID, myKey);
var app = module.exports = express.createServer();
app.get(function(request, response) {
response.statusCode = 404;
response.end("<h1>not found</h1>");
reporter.report404(request);
});
app.listen(3000);
node-404project
A simple client for reporting 404 server errors to the "404 project" at http://www.dshield.org/tools/404project.html.
Installation
npm install 404project
Usage
var express = require('express');
// the user id is usually a number, like 1234567
var myUserID='[Your ISC ID]';
var myKey='[Your Authentication Key]';
var reporter = require('404project').create(myUserID, myKey);
var app = module.exports = express.createServer();
app.get(function(request, response) {
response.statusCode = 404;
response.end("<h1>not found</h1>");
reporter.report404(request);
});
app.listen(3000);
更多
你可能也喜欢
- 68publishers-cookie-consent 中文文档教程
- 6otp-boot-component 中文文档教程
- @11thdeg/skaldstore 中文文档教程
- @1productaweek/react-modal-hooks 中文文档教程
- @4geit/swg-event-model 中文文档教程
- @8xprotocol/service-node-core 中文文档教程
- @abdoulaye.diallo.job/keycloack-admin 中文文档教程
- @abdulrahman48811/lotide 中文文档教程
- @ablestack/rdo-apollo-mobx-connector 中文文档教程
- @abstractmark/abstractmark 中文文档教程