ThinkJs2.0开发手册
快速入门
  • 介绍
  • 创建项目
  • 项目结构
  • 代码规范
  • 升级指南
进阶应用
  • 模块
  • 控制器
  • 视图
  • 配置
  • 路由
模型
  • 介绍
  • 事务
  • 关联模型
  • Mysql
  • MongoDB
  • SQLite
Adapter
  • 介绍
  • Cache
  • Session
  • WebSocket
  • Template
扩展功能
  • thinkjs 命令
  • 静态资源访问
  • Middleware
  • Service
  • Cookie
  • 错误处理
  • 错误信息
  • 数据校验
  • 国际化
  • 路径常量
  • REST API
  • 定时任务
  • 线上部署
  • 推荐模块
API
  • think
  • think.base
  • think.http.base
  • http
  • controller
  • rest controller
  • model
  • model.mongo
  • middleware
ThinkJs2.0开发手册APIhttp
上一篇:think.http.base 下一篇:controller

http

  • 属性
    • http.req
    • http.res
    • http.startTime
    • http.url
    • http.version
    • http.method
    • http.headers
    • http.pathname
    • http.query
    • http.host
    • http.hostname
    • http.payload
    • http._payloadParsed
    • http._get
    • http._post
    • http._file
    • http._cookie
    • 方法
      • http.config(name)
      • http.referrer()
      • http.userAgent()
      • http.isGet()
      • http.isPost()
      • http.isAjax(method)
      • http.isJsonp(name)
      • http.get(name, value)
      • http.post(name, value)
      • http.param(name)
      • http.file(name)
      • http.header(name, value)
      • http.expires(time)
      • http.status(status)
      • http.ip()
      • http.lang(lang, asViewPath)
      • http.theme(theme)
      • http.cookie(name, value)
      • http.session(name, value)
      • http.redirect(url, status)
      • http.type(contentType, encoding)
      • http.write(content, encoding)
      • http.end(content, encoding)
      • http.success(data, message)
      • http.fail(errno, errmsg, data)
      • http.json(data)
上一篇:think.http.base 下一篇:controller