node实验代码
来源:互联网 发布:中世纪2mod原版优化9 编辑:程序博客网 时间:2024/06/05 16:42
//requier表示引包,引包就是引用自己的一个特殊功能var http = require('http');//创建服务器参数是一个回调函数,表示如果有请求进来要做什么http.createServer(function handler(req, res) { //res表示请求,request;res表示响应,response //设置HTTP头部信息,状态码200,文件类型是“text/html” 字符集是utf8 res.writeHead(200, {'Content-Type': 'text/plain'}); res.end('Hello World\n');}).listen(1337, '127.0.0.1');console.log('Server running at http://127.0.0.1:1337/');
0 0
- node实验代码
- 实验代码
- node + Express 服务器性能实验
- node一些代码
- Node.js代码总结
- Node.js入门 - 概述和动手实验
- 数据结构实验的代码
- 流水灯实验代码
- 数据结构实验c++代码
- Kalman滤波实验代码
- 二叉树实验代码
- oracle实验和代码
- 数据库实验代码备份
- 实验二代码
- c++多线程实验代码
- 图形学实验代码
- 汇编实验代码
- GPIO实验代码
- 生物信息学习——tophat运行报错
- 死锁的四个条件
- Springboot 整合 Dubbo/ZooKeeper 详解 SOA 案例
- Executor框架简介-java并发编程
- HDU 4873ZCC Loves Intersection
- node实验代码
- 垃圾回收器——新生代收集器
- myeclipse--常用快捷键
- 去除ci index.php
- cstring与string头文件与输出
- apt-cache命令的常规用法
- Andriod内存
- 我从1万小时编程中学到了什么
- Node的特点